[JIRA] (JENKINS-38418) Failed to load persisted workflow state (remote-loader)

10 views
Skip to first unread message

escoem@gmail.com (JIRA)

unread,
Sep 21, 2016, 9:58:02 AM9/21/16
to jenkinsc...@googlegroups.com
Emilio Escobar created an issue
 
Jenkins / Bug JENKINS-38418
Failed to load persisted workflow state (remote-loader)
Issue Type: Bug Bug
Assignee: Oleg Nenashev
Components: pipeline, workflow-cps-plugin, workflow-remote-loader-plugin
Created: 2016/Sep/21 1:57 PM
Environment: Version: 1.651.3
workflow-cps:2.17
workflow-cps-global-lib:2.3
workflow-job:2.6
workflow-remote-loader:1.3
Priority: Minor Minor
Reporter: Emilio Escobar

The pipeline is unable to resume when using remote-loader-

node {
    stage 'Load a file from GitHub'
    def helloworld = fileLoader.fromGit('examples/fileLoader/helloworld', 'https://github.com/jenkinsci/workflow-remote-loader-plugin.git', 'master', null, '')

    sleep 15
    sh 'pwd'
    sh 'sleep 10'
    
    helloworld.printHello()

    stage '1'
    print 'here at stage1' 
}
[Pipeline] End of Pipeline
java.io.IOException: Failed to load persisted workflow state
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$3.onSuccess(CpsFlowExecution.java:585)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$3.onSuccess(CpsFlowExecution.java:583)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$4$1.run(CpsFlowExecution.java:626)
	at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$1.run(CpsVmExecutorService.java:32)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:112)
	at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassNotFoundException: org.jenkinsci.plugins.workflow.remoteloader.FileLoaderDSLImpl
	at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
	at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:692)
	at groovy.lang.GroovyClassLoader$InnerLoader.loadClass(GroovyClassLoader.java:445)
	at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:802)
	at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:790)
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:348)
	at org.jboss.marshalling.AbstractClassResolver.loadClass(AbstractClassResolver.java:131)
	at org.jboss.marshalling.AbstractClassResolver.resolveClass(AbstractClassResolver.java:112)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadClassDescriptor(RiverUnmarshaller.java:949)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1256)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
	at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:149)
	at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:135)
	at org.jboss.marshalling.MarshallerObjectInputStream.readObjectOverride(MarshallerObjectInputStream.java:53)
	at org.jboss.marshalling.river.RiverObjectInputStream.readObjectOverride(RiverObjectInputStream.java:307)
	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:365)
	at java.util.HashMap.readObject(HashMap.java:1396)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at org.jboss.marshalling.reflect.SerializableClass.callReadObject(SerializableClass.java:307)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1638)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1607)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1286)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
	at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:149)
	at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:135)
	at org.jboss.marshalling.MarshallerObjectInputStream.readObjectOverride(MarshallerObjectInputStream.java:53)
	at org.jboss.marshalling.river.RiverObjectInputStream.readObjectOverride(RiverObjectInputStream.java:307)
	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:365)
	at com.cloudbees.groovy.cps.SerializableScript.readObject(SerializableScript.java:30)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at org.jboss.marshalling.reflect.SerializableClass.callReadObject(SerializableClass.java:307)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1638)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1607)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1607)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1286)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:224)
	at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1746)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1659)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1607)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1607)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1286)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
	at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:149)
	at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:135)
	at org.jboss.marshalling.MarshallerObjectInputStream.readObjectOverride(MarshallerObjectInputStream.java:53)
	at org.jboss.marshalling.river.RiverObjectInputStream.readObjectOverride(RiverObjectInputStream.java:307)
	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:365)
	at java.util.HashMap.readObject(HashMap.java:1396)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at org.jboss.marshalling.reflect.SerializableClass.callReadObject(SerializableClass.java:307)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1638)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1286)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:224)
	at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1746)
	at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1659)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1286)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209)
	at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:41)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$2.onSuccess(CpsFlowExecution.java:514)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$2.onSuccess(CpsFlowExecution.java:507)
	at org.jenkinsci.plugins.workflow.support.concurrent.Futures$1.run(Futures.java:150)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.execute(ExecutionList.java:134)
	at com.google.common.util.concurrent.AbstractFuture.set(AbstractFuture.java:170)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture.access$000(ChainingListenableFuture.java:33)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture$1.run(ChainingListenableFuture.java:196)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.add(ExecutionList.java:105)
	at com.google.common.util.concurrent.AbstractFuture.addListener(AbstractFuture.java:155)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture.run(ChainingListenableFuture.java:189)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.execute(ExecutionList.java:134)
	at com.google.common.util.concurrent.AbstractFuture.set(AbstractFuture.java:170)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture.access$000(ChainingListenableFuture.java:33)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture$1.run(ChainingListenableFuture.java:196)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.add(ExecutionList.java:105)
	at com.google.common.util.concurrent.AbstractFuture.addListener(AbstractFuture.java:155)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture.run(ChainingListenableFuture.java:189)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.execute(ExecutionList.java:134)
	at com.google.common.util.concurrent.AbstractFuture.set(AbstractFuture.java:170)
	at org.jenkinsci.plugins.workflow.support.concurrent.ListFuture.setOneValue(ListFuture.java:158)
	at org.jenkinsci.plugins.workflow.support.concurrent.ListFuture.access$000(ListFuture.java:40)
	at org.jenkinsci.plugins.workflow.support.concurrent.ListFuture$2.run(ListFuture.java:107)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.execute(ExecutionList.java:134)
	at com.google.common.util.concurrent.AbstractFuture.set(AbstractFuture.java:170)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture.access$000(ChainingListenableFuture.java:33)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture$1.run(ChainingListenableFuture.java:196)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.add(ExecutionList.java:105)
	at com.google.common.util.concurrent.AbstractFuture.addListener(AbstractFuture.java:155)
	at org.jenkinsci.plugins.workflow.support.concurrent.ChainingListenableFuture.run(ChainingListenableFuture.java:189)
	at com.google.common.util.concurrent.MoreExecutors$SameThreadExecutorService.execute(MoreExecutors.java:253)
	at com.google.common.util.concurrent.ExecutionList$RunnableExecutorPair.execute(ExecutionList.java:149)
	at com.google.common.util.concurrent.ExecutionList.execute(ExecutionList.java:134)
	at com.google.common.util.concurrent.AbstractFuture.set(AbstractFuture.java:170)
	at org.jenkinsci.plugins.workflow.support.pickles.TryRepeatedly.access$500(TryRepeatedly.java:47)
	at org.jenkinsci.plugins.workflow.support.pickles.TryRepeatedly$1.run(TryRepeatedly.java:106)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
	... 3 more
Finished: FAILURE
Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

o.v.nenashev@gmail.com (JIRA)

unread,
Sep 21, 2016, 10:49:01 AM9/21/16
to jenkinsc...@googlegroups.com
Oleg Nenashev commented on Bug JENKINS-38418
 
Re: Failed to load persisted workflow state (remote-loader)

> java.lang.ClassNotFoundException: org.jenkinsci.plugins.workflow.remoteloader.FileLoaderDSLImpl

Are you sure the plugin is installed? If yes, potentially a wrong classloader for Groovy global vars is being used in Pipeline. CC Jesse Glick

escoem@gmail.com (JIRA)

unread,
Sep 21, 2016, 11:19:02 AM9/21/16
to jenkinsc...@googlegroups.com

Oleg Nenashev Yes, I am.

Started by user anonymous
[Pipeline] node
Running on master in /jenkins-home/workspace/pi1
[Pipeline] {
[Pipeline] stage (Load a file from GitHub)
Using the ‘stage’ step without a block argument is deprecated
Entering stage Load a file from GitHub
Proceeding
[Pipeline] node
Running on master in /jenkins-home/workspace/pi1@2
[Pipeline] {
[Pipeline] dir
Running in /jenkins-home/workspace/pi1@2/libLoader
[Pipeline] {
[Pipeline] deleteDir
[Pipeline] echo
Checking out https://github.com/jenkinsci/workflow-remote-loader-plugin.git, branch=master
[Pipeline] checkout
Cloning the remote Git repository
Cloning repository https://github.com/jenkinsci/workflow-remote-loader-plugin.git
 > git init /jenkins-home/workspace/pi1@2/libLoader # timeout=10
Fetching upstream changes from https://github.com/jenkinsci/workflow-remote-loader-plugin.git
 > git --version # timeout=10
 > git fetch --tags --progress https://github.com/jenkinsci/workflow-remote-loader-plugin.git +refs/heads/*:refs/remotes/origin/*
 > git config remote.origin.url https://github.com/jenkinsci/workflow-remote-loader-plugin.git # timeout=10
 > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
 > git config remote.origin.url https://github.com/jenkinsci/workflow-remote-loader-plugin.git # timeout=10
Fetching upstream changes from https://github.com/jenkinsci/workflow-remote-loader-plugin.git
 > git fetch --tags --progress https://github.com/jenkinsci/workflow-remote-loader-plugin.git +refs/heads/*:refs/remotes/origin/*
 > git rev-parse origin/master^{commit} # timeout=10
Checking out Revision 270024bf048c2210eabf0c5ff067476f55875727 (origin/master)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f 270024bf048c2210eabf0c5ff067476f55875727
[Pipeline] echo
Loading from examples/fileLoader/helloworld.groovy
[Pipeline] load
[Pipeline] { (examples/fileLoader/helloworld.groovy)
[Pipeline] }
[Pipeline] // load
[Pipeline] deleteDir
[Pipeline] }
[Pipeline] // dir
[Pipeline] }
[Pipeline] // node
[Pipeline] sleep
Sleeping for 15 sec
[Pipeline] sh
[pi1] Running shell script
+ pwd
/jenkins-home/workspace/pi1
[Pipeline] sh
[pi1] Running shell script
+ sleep 10
[Pipeline] echo
Hello, world!
[Pipeline] stage (1)
Using the ‘stage’ step without a block argument is deprecated
Entering stage 1
Proceeding
[Pipeline] echo
here at stage1
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline
Finished: SUCCESS

ryan.campbell@gmail.com (JIRA)

unread,
Sep 21, 2016, 11:57:06 AM9/21/16
to jenkinsc...@googlegroups.com

Can you please provide a list of steps to reproduce the issue? Please provide exact steps to reproduce in a fresh environment.

escoem@gmail.com (JIRA)

unread,
Sep 21, 2016, 12:31:01 PM9/21/16
to jenkinsc...@googlegroups.com

Sure @recampbell just build the pipeline and restart Jenkins while sleep is executed.

bhines@alumni.ucsd.edu (JIRA)

unread,
Sep 30, 2016, 5:38:01 PM9/30/16
to jenkinsc...@googlegroups.com

We are also seeing this issue on Jenkins 2.21 when using the remote loader. We're going to try not using remoteloader to workaround.

o.v.nenashev@gmail.com (JIRA)

unread,
Jan 11, 2017, 7:52:01 AM1/11/17
to jenkinsc...@googlegroups.com
Oleg Nenashev assigned an issue to Emilio Escobar
 
Change By: Oleg Nenashev
Assignee: Oleg Nenashev Emilio  Escobar

escoem@gmail.com (JIRA)

unread,
Feb 7, 2017, 4:26:02 AM2/7/17
to jenkinsc...@googlegroups.com
Emilio Escobar started work on Bug JENKINS-38418
 
Change By: Emilio Escobar
Status: Open In Progress

scm_issue_link@java.net (JIRA)

unread,
Feb 10, 2017, 6:14:02 AM2/10/17
to jenkinsc...@googlegroups.com
SCM/JIRA link daemon commented on Bug JENKINS-38418
 
Re: Failed to load persisted workflow state (remote-loader)

Code changed in jenkins
User: Emilio Escobar
Path:
src/main/java/org/jenkinsci/plugins/workflow/remoteloader/GroovyFileGlobalVariable.java
src/main/resources/org/jenkinsci/plugins/workflow/remoteloader/FileLoaderDSL/FileLoaderDSLImpl.groovy
src/main/resources/org/jenkinsci/plugins/workflow/remoteloader/FileLoaderDSL/Impl.groovy
http://jenkins-ci.org/commit/workflow-remote-loader-plugin/3c97d15e6636299756c778feb1f746879706435b
Log:
Merge pull request #13 from escoem/JENKINS-38418

[FIXED JENKINS-38418] Failed to load persisted workflow state (remote-loader). Thanks @oleg-nenashev

Compare: https://github.com/jenkinsci/workflow-remote-loader-plugin/compare/dcb1eb599b41...3c97d15e6636

scm_issue_link@java.net (JIRA)

unread,
Feb 10, 2017, 6:14:02 AM2/10/17
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Emilio Escobar
Path:
src/main/java/org/jenkinsci/plugins/workflow/remoteloader/GroovyFileGlobalVariable.java
src/main/resources/org/jenkinsci/plugins/workflow/remoteloader/FileLoaderDSL/FileLoaderDSLImpl.groovy
src/main/resources/org/jenkinsci/plugins/workflow/remoteloader/FileLoaderDSL/Impl.groovy

scm_issue_link@java.net (JIRA)

unread,
Feb 10, 2017, 6:14:02 AM2/10/17
to jenkinsc...@googlegroups.com
SCM/JIRA link daemon resolved as Fixed
 
Change By: SCM/JIRA link daemon
Status: In Progress Resolved
Resolution: Fixed

scm_issue_link@java.net (JIRA)

unread,
Feb 13, 2017, 6:46:01 AM2/13/17
to jenkinsc...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages