java.lang.RuntimeException: Failed to serialize hudson.model.Project#buildWrappers for class hudson.model.FreeStyleProject

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • Hello Hudson folks, first of all: Really great work! Hudson really helps me getting some automation work done in a chaotic project. But I've found an annoying and data eating bug. *Problem*: If I create a new job or modify an existing job right after Hudson's startup everything is fine. Buf if I modify or create a job and _then_ try to modfiy the _same job a second time_, hudson displays an "Status Code: 500" page and all changes I've made are lost. It does not have any influence if I modify other jobs in the meantime. *Workaround*: If I restart Hudson or use the "copy existing job" functinality I have "one modification free". But I cannot restart Hudson everytime I need to make an modification to an job or loose all job history by copy and rename a job I have to modify. _Interessting observation_: If I try and delte a job, I'll get the same "Status Code: 500" page. But if I press the "one page back" button in my browser the job is marked as inactive and another try will delete the job. The main part of the stack trace seems to me (whole message attached): {quote} java.lang.RuntimeException: Failed to serialize hudson.model.Project#buildWrappers for class hudson.model.FreeStyleProject at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:164) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) ... Caused by: java.lang.RuntimeException: Failed to serialize hudson.plugins.envfile.EnvFileBuildWrapper#buildListner for class hudson.plugins.envfile.EnvFileBuildWrapper at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:164) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) ... Caused by: com.thoughtworks.xstream.converters.ConversionException: Could not call hudson.model.StreamBuildListener.writeObject() : Could not call hudson.remoting.RemoteOutputStream.writeObject() : null ---- Debugging information ---- message : Could not call hudson.remoting.RemoteOutputStream.writeObject() cause-exception : java.lang.NullPointerException cause-message : null ------------------------------- message : Could not call hudson.model.StreamBuildListener.writeObject() cause-exception : com.thoughtworks.xstream.converters.ConversionException cause-message : Could not call hudson.remoting.RemoteOutputStream.writeObject() : null ------------------------------- ... {quote}
    via by ssplett,
  • Hello Hudson folks, first of all: Really great work! Hudson really helps me getting some automation work done in a chaotic project. But I've found an annoying and data eating bug. *Problem*: If I create a new job or modify an existing job right after Hudson's startup everything is fine. Buf if I modify or create a job and _then_ try to modfiy the _same job a second time_, hudson displays an "Status Code: 500" page and all changes I've made are lost. It does not have any influence if I modify other jobs in the meantime. *Workaround*: If I restart Hudson or use the "copy existing job" functinality I have "one modification free". But I cannot restart Hudson everytime I need to make an modification to an job or loose all job history by copy and rename a job I have to modify. _Interessting observation_: If I try and delte a job, I'll get the same "Status Code: 500" page. But if I press the "one page back" button in my browser the job is marked as inactive and another try will delete the job. The main part of the stack trace seems to me (whole message attached): {quote} java.lang.RuntimeException: Failed to serialize hudson.model.Project#buildWrappers for class hudson.model.FreeStyleProject at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:164) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) ... Caused by: java.lang.RuntimeException: Failed to serialize hudson.plugins.envfile.EnvFileBuildWrapper#buildListner for class hudson.plugins.envfile.EnvFileBuildWrapper at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:164) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) ... Caused by: com.thoughtworks.xstream.converters.ConversionException: Could not call hudson.model.StreamBuildListener.writeObject() : Could not call hudson.remoting.RemoteOutputStream.writeObject() : null ---- Debugging information ---- message : Could not call hudson.remoting.RemoteOutputStream.writeObject() cause-exception : java.lang.NullPointerException cause-message : null ------------------------------- message : Could not call hudson.model.StreamBuildListener.writeObject() cause-exception : com.thoughtworks.xstream.converters.ConversionException cause-message : Could not call hudson.remoting.RemoteOutputStream.writeObject() : null ------------------------------- ... {quote}
    via by ssplett,
  • This happens from time to time. Dec 7, 2010 1:09:13 PM hudson.model.Executor run SEVERE: Executor threw an exception java.lang.RuntimeException: Failed to serialize hudson.model.Actionable#actions for class hudson.model.FreeStyleBuild at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:167) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) at hudson.util.RobustReflectionConverter.doMarshal(RobustReflectionConverter.java:120) at hudson.util.RobustReflectionConverter.marshal(RobustReflectionConverter.java:94) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at com.thoughtworks.xstream.core.TreeMarshaller.start(TreeMarshaller.java:98) at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.marshal(AbstractTreeMarshallingStrategy.java:38) at com.thoughtworks.xstream.XStream.marshal(XStream.java:840) at com.thoughtworks.xstream.XStream.marshal(XStream.java:829) at com.thoughtworks.xstream.XStream.toXML(XStream.java:804) at hudson.XmlFile.write(XmlFile.java:165) at hudson.model.Run.save(Run.java:1403) at com.sonyericsson.hudson.plugins.gerrit.trigger.gerritnotifier.model.BuildMemory.updateTriggerContext(BuildMemory.java:265) at com.sonyericsson.hudson.plugins.gerrit.trigger.gerritnotifier.ToGerritRunListener.onCompleted(ToGerritRunListener.java:85) at com.sonyericsson.hudson.plugins.gerrit.trigger.gerritnotifier.ToGerritRunListener.onCompleted(ToGerritRunListener.java:45) at hudson.model.listeners.RunListener.fireCompleted(RunListener.java:126) at hudson.model.Run.run(Run.java:1321) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:137) Caused by: java.lang.RuntimeException: Failed to serialize hudson.model.CauseAction#causes for class hudson.model.CauseAction at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:167) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) at hudson.util.RobustReflectionConverter.doMarshal(RobustReflectionConverter.java:120) at hudson.util.RobustReflectionConverter.marshal(RobustReflectionConverter.java:94) at hudson.util.XStream2$PassthruConverter.marshal(XStream2.java:246) at hudson.util.XStream2$AssociatedConverterImpl.marshal(XStream2.java:216) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at com.thoughtworks.xstream.converters.collections.AbstractCollectionConverter.writeItem(AbstractCollectionConverter.java:64) at com.thoughtworks.xstream.converters.collections.CollectionConverter.marshal(CollectionConverter.java:55) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:175) at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:163) ... 22 more Caused by: java.lang.RuntimeException: Failed to serialize com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.GerritCause#context for class com.sonyericsson.hudson.plugins.gerr it.trigger.hudsontrigger.GerritManualCause at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:167) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) at hudson.util.RobustReflectionConverter.doMarshal(RobustReflectionConverter.java:120) at hudson.util.RobustReflectionConverter.marshal(RobustReflectionConverter.java:94) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at com.thoughtworks.xstream.converters.collections.AbstractCollectionConverter.writeItem(AbstractCollectionConverter.java:64) at com.thoughtworks.xstream.converters.collections.CollectionConverter.marshal(CollectionConverter.java:55) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:175) at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:163) ... 38 more Caused by: java.lang.NullPointerException at com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.TriggerContextConverter.marshalItemEntity(TriggerContextConverter.java:51) at com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.TriggerContextConverter.marshal(TriggerContextConverter.java:29) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:175) at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:163) ... 52 more
    via by rsandell,
  • I have a project which use the Klocwork plug-in to: - Build using a build specification - Publish Klocwork test result report (default klocwork_result.xml) Every times i restart Jenkins, the entire build history is lost for the project. In _$HUDSON_HOME/jobs/MY_PROJECT/builds_ i can still access all the builds, but *build.xml* files are missing, and there are remaining tmp files in _/workspace-files_ directory ------------ Aug 14, 2012 5:57:23 PM hudson.model.Executor run SEVERE: Executor threw an exception java.lang.RuntimeException: Failed to serialize hudson.model.Actionable#actions for class hudson.model.FreeStyleBuild at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:167) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) at hudson.util.RobustReflectionConverter.doMarshal(RobustReflectionConverter.java:120) at hudson.util.RobustReflectionConverter.marshal(RobustReflectionConverter.java:94) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at com.thoughtworks.xstream.core.TreeMarshaller.start(TreeMarshaller.java:98) at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.marshal(AbstractTreeMarshallingStrategy.java:38) at com.thoughtworks.xstream.XStream.marshal(XStream.java:840) at com.thoughtworks.xstream.XStream.marshal(XStream.java:829) at com.thoughtworks.xstream.XStream.toXML(XStream.java:804) at hudson.XmlFile.write(XmlFile.java:177) at hudson.model.Run.save(Run.java:1624) at hudson.model.Run.execute(Run.java:1546) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:236) *Caused by: java.lang.RuntimeException: Failed to serialize com.thalesgroup.hudson.plugins.klocwork.util.KloBuildLog#kloTables for class com.thalesgroup.hudson.plugins.klocwork.util.KloBuildLog* at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:167) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130) at hudson.util.RobustReflectionConverter.doMarshal(RobustReflectionConverter.java:120) at hudson.util.RobustReflectionConverter.marshal(RobustReflectionConverter.java:94) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:63) at com.thoughtworks.xstream.converters.collections.AbstractCollectionConverter.writeItem(AbstractCollectionConverter.java:64) at com.thoughtworks.xstream.converters.collections.CollectionConverter.marshal(CollectionConverter.java:55) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:176) at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:163) ... 18 more Caused by: com.thoughtworks.xstream.converters.ConversionException: Could not call hudson.FilePath.writeObject() : Can't send a remote FilePath to a different remote channel ---- Debugging information ---- message : Could not call hudson.FilePath.writeObject() cause-exception : java.lang.IllegalStateException cause-message : Can't send a remote FilePath to a different remote channel ------------------------------- at com.thoughtworks.xstream.converters.reflection.SerializationMethodInvoker.callWriteObject(SerializationMethodInvoker.java:104) at com.thoughtworks.xstream.converters.reflection.SerializableConverter.doMarshal(SerializableConverter.java:215) at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.marshal(AbstractReflectionConverter.java:58) at com.thoughtworks.xstream.core.AbstractReferenceMarshaller.convert(AbstractReferenceMarshaller.java:68) at com.thoughtworks.xstream.core.TreeMarshaller.convertAnother(TreeMarshaller.java:78) at hudson.util.RobustReflectionConverter.marshallField(RobustReflectionConverter.java:176) at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:163) ... 31 more Caused by: java.lang.IllegalStateException: Can't send a remote FilePath to a different remote channel at hudson.FilePath.writeObject(FilePath.java:2153) at sun.reflect.GeneratedMethodAccessor343.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:616) at com.thoughtworks.xstream.converters.reflection.SerializationMethodInvoker.callWriteObject(SerializationMethodInvoker.java:100) ... 37 more Aug 14, 2012 5:57:22 PM hudson.model.Run execute ----------- I tried to deactivate the "Publish Klocwork test result report". All the builds performed with this configuration are loaded and shown in the build history (build.xml file is present).
    via by Geoffroy Jabouley,
    • java.lang.RuntimeException: Failed to serialize hudson.model.Project#buildWrappers for class hudson.model.FreeStyleProject at hudson.util.RobustReflectionConverter$2.writeField(RobustReflectionConverter.java:164) at hudson.util.RobustReflectionConverter$2.visit(RobustReflectionConverter.java:135) at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(PureJavaReflectionProvider.java:130)

    Users with the same issue

    Unknown visitor1 times, last one,
    davidvanlaatum
    davidvanlaatum2 times, last one,