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

java.lang.RuntimeException: Failed to serialize hudson.model.Actionable#actions for class hudson.matrix.MatrixBuild

      23:19:07 FATAL: java.lang.RuntimeException: Failed to serialize hudson.model.Actionable#actions for class hudson.matrix.MatrixBuild
      23:19:07 java.lang.UnsupportedOperationException: Refusing to marshal java.io.PrintStream for security reasons; see https://jenkins.io/redirect/class-filter/
      23:19:07 	at hudson.util.XStream2$BlacklistedTypesConverter.marshal(XStream2.java:546)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:69)
      23:19:07 	at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:58)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractReferenceMarshaller$1.convertAnother(AbstractReferenceMarshaller.java:84)
      23:19:07 	at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:265)
      23:19:07 	at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:252)
      23:19:07 Caused: java.lang.RuntimeException: Failed to serialize org.jenkinsci.plugins.EnvironmentVarSetter#log for class org.jenkinsci.plugins.EnvironmentVarSetter
      23:19:07 	at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:256)
      23:19:07 	at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:224)
      23:19:07 	at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:138)
      23:19:07 	at hudson.util.RobustReflectionConverter.doMarshal(RobustReflectionConverter.java:209)
      23:19:07 	at hudson.util.RobustReflectionConverter.marshal(RobustReflectionConverter.java:150)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:69)
      23:19:07 	at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:58)
      23:19:07 	at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:43)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractReferenceMarshaller$1.convertAnother(AbstractReferenceMarshaller.java:88)
      23:19:07 	at com.thoughtworks.xstream.converters.collections.AbstractCollectionConverter.writeItem(AbstractCollectionConverter.java:64)
      23:19:07 	at com.thoughtworks.xstream.converters.collections.CollectionConverter.marshal(CollectionConverter.java:74)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:69)
      23:19:07 	at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:58)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractReferenceMarshaller$1.convertAnother(AbstractReferenceMarshaller.java:84)
      23:19:07 	at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:265)
      23:19:07 	at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:252)
      23:19:07 Caused: java.lang.RuntimeException: Failed to serialize hudson.model.Actionable#actions for class hudson.matrix.MatrixBuild
      23:19:07 	at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:256)
      23:19:07 	at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:224)
      23:19:07 	at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:138)
      23:19:07 	at hudson.util.RobustReflectionConverter.doMarshal(RobustReflectionConverter.java:209)
      23:19:07 	at hudson.util.RobustReflectionConverter.marshal(RobustReflectionConverter.java:150)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:69)
      23:19:07 	at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:58)
      23:19:07 	at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:43)
      23:19:07 	at com.thoughtworks.xstream.core.TreeMarshaller.start(TreeMarshaller.java:82)
      23:19:07 	at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.marshal(AbstractTreeMarshallingStrategy.java:37)
      23:19:07 	at com.thoughtworks.xstream.XStream.marshal(XStream.java:1026)
      23:19:07 	at com.thoughtworks.xstream.XStream.marshal(XStream.java:1015)
      23:19:07 	at com.thoughtworks.xstream.XStream.toXML(XStream.java:988)
      23:19:07 	at hudson.XmlFile.write(XmlFile.java:193)
      23:19:07 Caused: java.io.IOException
      23:19:07 	at hudson.XmlFile.write(XmlFile.java:200)
      23:19:07 	at hudson.model.Run.save(Run.java:2011)
      23:19:07 	at hudson.model.Run.setDisplayName(Run.java:807)
      23:19:07 	at org.jenkinsci.plugins.buildnamesetter.BuildNameSetter.setDisplayName(BuildNameSetter.java:76)
      23:19:07 	at org.jenkinsci.plugins.buildnamesetter.BuildNameSetter.access$000(BuildNameSetter.java:31)
      23:19:07 	at org.jenkinsci.plugins.buildnamesetter.BuildNameSetter$2.endBuild(BuildNameSetter.java:93)
      23:19:07 	at hudson.matrix.MatrixBuild$MatrixBuildExecution.post2(MatrixBuild.java:433)
      23:19:07 	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
      23:19:07 	at hudson.model.Run.execute(Run.java:1840)
      23:19:07 	at hudson.matrix.MatrixBuild.run(MatrixBuild.java:323)
      23:19:07 	at hudson.model.ResourceController.execute(ResourceController.java:97)
      23:19:07 	at hudson.model.Executor.run(Executor.java:429) 

      JEP-200 related

      Jenkins 2.138
      Matrix Project Plugin 1.13

          [JENKINS-54362] java.lang.RuntimeException: Failed to serialize hudson.model.Actionable#actions for class hudson.matrix.MatrixBuild

          Oleg Nenashev added a comment -

          Have you updated the Build Name Setter plugin?

          Oleg Nenashev added a comment - Have you updated the Build Name Setter plugin?

          Jack Newcombe added a comment -

          Yes, I have build-name-setter 1.6.7

          I also find that build name setter only works when setting at the start of the build, but not the end (causes a similar IOException)

          Jack Newcombe added a comment - Yes, I have build-name-setter 1.6.7 I also find that build name setter only works when setting at the start of the build, but not the end (causes a similar IOException)

          Oleg Nenashev added a comment -

          "
          Failed to serialize org.jenkinsci.plugins.EnvironmentVarSetter#log for class org.jenkinsci.plugins.EnvironmentVarSetter
          "

          It clearly says that you need to update to 1.6.8. See  JENKINS-48944 

          Oleg Nenashev added a comment - " Failed to serialize org.jenkinsci.plugins.EnvironmentVarSetter#log for class org.jenkinsci.plugins.EnvironmentVarSetter " It clearly says that you need to update to 1.6.8. See   JENKINS-48944  

          Jack Newcombe added a comment -

          oleg_nenashev 1.6.7 is the latest available on my Jenkins installation.

          It looks like >= 1.6.8 were released a while ago - is there a reason why this might not appear in the update center?

          My update center url is https://updates.jenkins.io/update-center.json

          Jack Newcombe added a comment - oleg_nenashev 1.6.7 is the latest available on my Jenkins installation. It looks like >= 1.6.8 were released a while ago - is there a reason why this might not appear in the update center? My update center url is https://updates.jenkins.io/update-center.json

          Oleg Nenashev added a comment -

          No idea what could be causing it. Maybe you are running on old Java which does not support LetsEncrypt. In such case your Jenkins will fail to pull new metadata from the update center, but it should print errors to the system log.

           CC danielbeck who knows the UC infrastructure better than me

          Oleg Nenashev added a comment - No idea what could be causing it. Maybe you are running on old Java which does not support LetsEncrypt. In such case your Jenkins will fail to pull new metadata from the update center, but it should print errors to the system log.  CC danielbeck who knows the UC infrastructure better than me

          Jack Newcombe added a comment - - edited

          oleg_nenashev thank you, is there a recommended java version? I wouldn't be against upgrading if it's necessary.

          (Sounds like it might be sensible anyway, even if not related to this issue)

          Jack Newcombe added a comment - - edited oleg_nenashev thank you, is there a recommended java version? I wouldn't be against upgrading if it's necessary. (Sounds like it might be sensible anyway, even if not related to this issue)

          Oleg Nenashev added a comment -

          I recommend the latest OpenJDK 8 version

          Oleg Nenashev added a comment - I recommend the latest OpenJDK 8 version

          Jack Newcombe added a comment - - edited

          OK thanks, according to dpkg this is what we have installed:

          ii  openjdk-8-jdk:amd64              8u111-b14-3~14.04.1                        amd64        OpenJDK Development Kit (JDK)
          ii  openjdk-8-jdk-headless:amd64     8u111-b14-3~14.04.1                        amd64        OpenJDK Development Kit (JDK) (headless)
          ii  openjdk-8-jre:amd64              8u111-b14-3~14.04.1                        amd64        OpenJDK Java runtime, using Hotspot JIT
          ii  openjdk-8-jre-headless:amd64     8u111-b14-3~14.04.1                        amd64        OpenJDK Java runtime, using Hotspot JIT (headless)
          

          and java -version returns 1.8.0_111 (same for javac)

          Jack Newcombe added a comment - - edited OK thanks, according to dpkg this is what we have installed: ii openjdk-8-jdk:amd64 8u111-b14-3~14.04.1 amd64 OpenJDK Development Kit (JDK) ii openjdk-8-jdk-headless:amd64 8u111-b14-3~14.04.1 amd64 OpenJDK Development Kit (JDK) (headless) ii openjdk-8-jre:amd64 8u111-b14-3~14.04.1 amd64 OpenJDK Java runtime, using Hotspot JIT ii openjdk-8-jre-headless:amd64 8u111-b14-3~14.04.1 amd64 OpenJDK Java runtime, using Hotspot JIT (headless) and java -version returns 1.8.0_111 (same for javac)

          Daniel Beck added a comment -

          Workaround might be to use an HTTP URL.

          Otherwise, just download manually and upload in Advanced tab.

          Daniel Beck added a comment - Workaround might be to use an HTTP URL. Otherwise, just download manually and upload in Advanced tab.

          Jack Newcombe added a comment -

          I tried setting the update URL to use http instead of https, but to no avail.

          Also I've run through the latest logs after hitting the "Check Now" button a few times and, other than the issue here, everything looks as expected (I can't post the log here without redacting information which I don't have the time to do unfortunately).

          danielbeck Any other possible workarounds? I'll update manually for now but this naturally doesn't scale well and I don't know which other plugin updates may be missing.

          I see updates for other plugins that are fairly recent (this week) so I'm left to assume update center is functioning correctly, but that the build name setter plugin update details, and potentially others, are not being returned.

          Jack Newcombe added a comment - I tried setting the update URL to use http instead of https, but to no avail. Also I've run through the latest logs after hitting the "Check Now" button a few times and, other than the issue here, everything looks as expected (I can't post the log here without redacting information which I don't have the time to do unfortunately). danielbeck Any other possible workarounds? I'll update manually for now but this naturally doesn't scale well and I don't know which other plugin updates may be missing. I see updates for other plugins that are fairly recent (this week) so I'm left to assume update center is functioning correctly, but that the build name setter plugin update details, and potentially others, are not being returned.

            Unassigned Unassigned
            jnewc Jack Newcombe
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: