Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-47416

Views deleted by upgrade from cloudbees-folders 6.1.2 to 6.2.0

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Labels:
    • Environment:
      Docker image running Jenkins 2.73.2
      cloudbees-folder-plugin 6.2.0
      upgrading folders from prior cloudbees-folder-plugin
    • Similar Issues:

      Description

      When I installed cloudbees-folder-plugin 6.2.0, the views defined in several of my folders were deleted.

      An administrative monitor appeared warning about unreadable data. The message was:

      ConversionException: Could not call com.cloudbees.hudson.plugins.folder.views.DefaultFolderViewHolder.readResolve() :
      no parent set on com.cloudbees.hudson.plugins.folder.Folder[null] :
      Could not call com.cloudbees.hudson.plugins.folder.views.DefaultFolderViewHolder.readResolve() :
      no parent set on com.cloudbees.hudson.plugins.folder.Folder[null]
      ---- Debugging information ----
      message : Could not call com.cloudbees.hudson.plugins.folder.views.DefaultFolderViewHolder.readResolve() : no parent set on com.cloudbees.hudson.plugins.folder.Folder[null]
      cause-exception : com.thoughtworks.xstream.converters.reflection.ObjectAccessException
      cause-message : Could not call com.cloudbees.hudson.plugins.folder.views.DefaultFolderViewHolder.readResolve() : no parent set on com.cloudbees.hudson.plugins.folder.Folder[null]
      class : com.cloudbees.hudson.plugins.folder.views.DefaultFolderViewHolder required-type : com.cloudbees.hudson.plugins.folder.views.DefaultFolderViewHolder
      converter-type : hudson.util.RobustReflectionConverter path
      : /com.cloudbees.hudson.plugins.folder.Folder/folderViews line number : 157 -------------------------------
      

      To duplicate the problem:

      1. Clone, build, and run the docker instance
          $ git lfs clone https://github.com/MarkEWaite/docker-lfs JENKINS-47416
          $ cd JENKINS-47416
          $ git lfs fetch origin JENKINS-47416
          $ git checkout -b lts-with-plugins JENKINS-47416
          $ docker build -t jenkins:JENKINS-47416 .
          $ docker run -i --rm --publish 8080:8080 jenkins:JENKINS-47416
        
      2. Click "Manage Jenkins"
      3. Clck the "Manage" button to the right of "You have data stored in an older format and/or unreadable data" (opens http://localhost:8080/administrativeMonitor/OldData/manage )

      One of the folder config.xml files is available in the docker image

      Conversion exception is thrown even if I update the folder definition to 6.1.2 format before upgrading the cloudbees-folders plugin.

        Attachments

          Issue Links

            Activity

            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            core/src/main/java/hudson/model/AllView.java
            http://jenkins-ci.org/commit/jenkins/6a2e907e7d4c00ae673a054cc3c65feb24f559de
            Log:
            JENKINS-47416 ViewGroup.getUrl could throw NPE during deserialization, so do not call it from migrateLegacyPrimaryAllViewLocalizedName.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: core/src/main/java/hudson/model/AllView.java http://jenkins-ci.org/commit/jenkins/6a2e907e7d4c00ae673a054cc3c65feb24f559de Log: JENKINS-47416 ViewGroup.getUrl could throw NPE during deserialization, so do not call it from migrateLegacyPrimaryAllViewLocalizedName.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            core/src/main/java/hudson/model/AllView.java
            http://jenkins-ci.org/commit/jenkins/8ac33fdecea0dfe92450594dadac799e4b3b1f2d
            Log:
            Merge pull request #3088 from jglick/JENKINS-47416

            JENKINS-47416 Do not call ViewGroup.getUrl from migrateLegacyPrimaryAllViewLocalizedName

            Compare: https://github.com/jenkinsci/jenkins/compare/3be716b8373d...8ac33fdecea0

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: core/src/main/java/hudson/model/AllView.java http://jenkins-ci.org/commit/jenkins/8ac33fdecea0dfe92450594dadac799e4b3b1f2d Log: Merge pull request #3088 from jglick/ JENKINS-47416 JENKINS-47416 Do not call ViewGroup.getUrl from migrateLegacyPrimaryAllViewLocalizedName Compare: https://github.com/jenkinsci/jenkins/compare/3be716b8373d...8ac33fdecea0
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            src/main/java/com/cloudbees/hudson/plugins/folder/views/DefaultFolderViewHolder.java
            http://jenkins-ci.org/commit/cloudbees-folder-plugin/cbde5251843625f389f4be956d0e9d4d3055516c
            Log:
            Noting merge of JENKINS-47416.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: src/main/java/com/cloudbees/hudson/plugins/folder/views/DefaultFolderViewHolder.java http://jenkins-ci.org/commit/cloudbees-folder-plugin/cbde5251843625f389f4be956d0e9d4d3055516c Log: Noting merge of JENKINS-47416 .
            Hide
            markewaite Mark Waite added a comment -

            Verified fixed in folders 6.2.1

            Show
            markewaite Mark Waite added a comment - Verified fixed in folders 6.2.1
            Hide
            jglick Jesse Glick added a comment -

            Regarding lts-candidate status: the fix should be harmless (it is hard to see how it could cause any regression); OTOH it is not very important, as it only affects users of cloudbees-folder 6.2.0. Having the fix backported to 2.73.3 would make it possible to remove the plugin workaround a little earlier, that is all.

            Show
            jglick Jesse Glick added a comment - Regarding lts-candidate status: the fix should be harmless (it is hard to see how it could cause any regression); OTOH it is not very important, as it only affects users of cloudbees-folder 6.2.0. Having the fix backported to 2.73.3 would make it possible to remove the plugin workaround a little earlier, that is all.

              People

              • Assignee:
                jglick Jesse Glick
                Reporter:
                markewaite Mark Waite
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: