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

restore class compatibility for AbstractTaskListener

    XMLWordPrintable

Details

    Description

      https://github.com/jenkinsci/jenkins/pull/3122 changed the AbstractTaskListener in a non serialization friendly way.

      For Jenkins this is not normally a problem as the same versions of classes will be used on both ends of a remoting endpoint, but custom derivatives may not have this luxury, or may use a different form of serialization other than XStream.

      The simple fix that appears to work is to restore the serialVersionUID to the pre change version.

      Attachments

        Issue Links

          Activity

            Code changed in jenkins
            User: James Nord
            Path:
            core/src/main/java/hudson/util/AbstractTaskListener.java
            http://jenkins-ci.org/commit/jenkins/dcf22ca809671f19cfc2d1d10537b7bb5cf56e8d
            Log:
            JENKINS-50124 restore AbstractTaskListeners serialVersionUID.

            If a subclass was serialized (default java serialization) then the
            changes do push down the method to the interface would break
            deserialisation when in reality the classes are still compatable.

            Restoring the compatability by hard coding the serialVersionUID to what
            it was before the change.

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: James Nord Path: core/src/main/java/hudson/util/AbstractTaskListener.java http://jenkins-ci.org/commit/jenkins/dcf22ca809671f19cfc2d1d10537b7bb5cf56e8d Log: JENKINS-50124 restore AbstractTaskListeners serialVersionUID. If a subclass was serialized (default java serialization) then the changes do push down the method to the interface would break deserialisation when in reality the classes are still compatable. Restoring the compatability by hard coding the serialVersionUID to what it was before the change.

            Code changed in jenkins
            User: James Nord
            Path:
            core/src/main/java/hudson/util/AbstractTaskListener.java
            http://jenkins-ci.org/commit/jenkins/18e535fa5052f39498a93a508362ea5730efee6d
            Log:
            Merge pull request #3346 from jtnord/JENKINS-50124

            JENKINS-50124 restore AbstractTaskListeners serialVersionUID.

            Compare: https://github.com/jenkinsci/jenkins/compare/dcad69dda844...18e535fa5052

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: James Nord Path: core/src/main/java/hudson/util/AbstractTaskListener.java http://jenkins-ci.org/commit/jenkins/18e535fa5052f39498a93a508362ea5730efee6d Log: Merge pull request #3346 from jtnord/ JENKINS-50124 JENKINS-50124 restore AbstractTaskListeners serialVersionUID. Compare: https://github.com/jenkinsci/jenkins/compare/dcad69dda844...18e535fa5052
            teilo James Nord added a comment -

            released towards Jenkins 2.112

            teilo James Nord added a comment - released towards Jenkins 2.112
            teilo James Nord added a comment -

            recena is there a need to backport this to 2.107.2? if not can you remove the "lts-candidate" label

            teilo James Nord added a comment - recena is there a need to backport this to 2.107.2? if not can you remove the "lts-candidate" label

            Code changed in jenkins
            User: James Nord
            Path:
            core/src/main/java/hudson/util/AbstractTaskListener.java
            http://jenkins-ci.org/commit/jenkins/99592e0a84d9dc6bbda457040f91719aa153dfec
            Log:
            JENKINS-50124 restore AbstractTaskListeners serialVersionUID.

            If a subclass was serialized (default java serialization) then the
            changes do push down the method to the interface would break
            deserialisation when in reality the classes are still compatable.

            Restoring the compatability by hard coding the serialVersionUID to what
            it was before the change.

            (cherry picked from commit dcf22ca809671f19cfc2d1d10537b7bb5cf56e8d)

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: James Nord Path: core/src/main/java/hudson/util/AbstractTaskListener.java http://jenkins-ci.org/commit/jenkins/99592e0a84d9dc6bbda457040f91719aa153dfec Log: JENKINS-50124 restore AbstractTaskListeners serialVersionUID. If a subclass was serialized (default java serialization) then the changes do push down the method to the interface would break deserialisation when in reality the classes are still compatable. Restoring the compatability by hard coding the serialVersionUID to what it was before the change. (cherry picked from commit dcf22ca809671f19cfc2d1d10537b7bb5cf56e8d)

            People

              Unassigned Unassigned
              teilo James Nord
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: