Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JENKINS-41854] Interpret DynamicContext #291

Merged
merged 9 commits into from
Jun 3, 2019

Conversation

jglick
Copy link
Member

@jglick jglick commented Jun 1, 2019

@jglick jglick requested a review from dwnusbaum June 1, 2019 00:01
Copy link
Member

@dwnusbaum dwnusbaum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, I like this approach better!

pom.xml Outdated Show resolved Hide resolved
Co-Authored-By: Devin Nusbaum <dwnusbaum@users.noreply.github.com>
pom.xml Outdated Show resolved Hide resolved
Co-Authored-By: Devin Nusbaum <dwnusbaum@users.noreply.github.com>
@dwnusbaum dwnusbaum merged commit 3aadbc1 into jenkinsci:master Jun 3, 2019
@jglick jglick deleted the DynamicContext-JENKINS-41854 branch June 3, 2019 23:37
@basil
Copy link
Member

basil commented Jun 6, 2019

I tested an upgrade on my staging instance from 2.150.1 to 2.176. These were the plugin updates:

diff --git a/docker/jenkins/selfservice/plugins.txt b/docker/jenkins/selfservice/plugins.txt
index a67c1753..40d39bda 100644
--- a/docker/jenkins/selfservice/plugins.txt
+++ b/docker/jenkins/selfservice/plugins.txt
@@ -34,7 +34,7 @@ datadog:0.6.5
 display-url-api:2.3.0
 docker-commons:1.13
 docker-workflow:1.17
-durable-task:1.28
+durable-task:1.29
 email-ext:2.63
 envinject-api:1.5
 envinject:2.1.6
@@ -78,31 +78,31 @@ monitoring:1.75.0
 nodelabelparameter:1.7.2
 pam-auth:1.4
 parameterized-trigger:2.35.2
-pipeline-build-step:2.7
+pipeline-build-step:2.9
 pipeline-github-lib:1.0
 pipeline-githubnotify-step:1.0.4
-pipeline-graph-analysis:1.9
-pipeline-input-step:2.9
+pipeline-graph-analysis:1.10
+pipeline-input-step:2.10
 pipeline-milestone-step:1.3.1
-pipeline-model-api:1.3.4
+pipeline-model-api:1.3.8
 pipeline-model-declarative-agent:1.1.1
-pipeline-model-definition:1.3.4
-pipeline-model-extensions:1.3.4
-pipeline-rest-api:2.10
+pipeline-model-definition:1.3.8
+pipeline-model-extensions:1.3.8
+pipeline-rest-api:2.11
 pipeline-stage-step:2.3
-pipeline-stage-tags-metadata:1.3.4
-pipeline-stage-view:2.10
-pipeline-utility-steps:2.2.0
+pipeline-stage-tags-metadata:1.3.8
+pipeline-stage-view:2.11
+pipeline-utility-steps:2.3.0
 plain-credentials:1.5
-rebuild:1.29
+rebuild:1.31
 resource-disposer:0.12
 run-condition:1.2
 scm-api:2.3.0
-script-security:1.49
+script-security:1.60
 slack:2.11
 ssh-credentials:1.14
 ssh-slaves:1.29.1
-structs:1.17
+structs:1.19
 subversion:2.12.1
 swarm:3.17
 test-results-analyzer:0.3.5
@@ -113,14 +113,14 @@ token-macro:2.5
 trilead-api:1.0.1
 windows-slaves:1.3.1
 workflow-aggregator:2.6
-workflow-api:2.33
-workflow-basic-steps:2.13
-workflow-cps:2.61
-workflow-cps-global-lib:2.12
-workflow-durable-task-step:2.27
-workflow-job:2.31
-workflow-multibranch:2.20
-workflow-scm-step:2.7
-workflow-step-api:2.17
-workflow-support:2.24
+workflow-api:2.34
+workflow-basic-steps:2.18
+workflow-cps:2.70
+workflow-cps-global-lib:2.13
+workflow-durable-task-step:2.31
+workflow-job:2.32
+workflow-multibranch:2.21
+workflow-scm-step:2.8
+workflow-step-api:2.20
+workflow-support:3.3
 ws-cleanup:0.37

Unfortunately, none of my jobs resumed correctly after the upgrade. They all failed with exceptions like this:

Resuming build at Thu Jun 06 16:59:30 UTC 2019 after Jenkins restart
[Pipeline] End of Pipeline
hudson.remoting.ProxyException: an exception which occurred:
	in element at index [0] of size [7]
Caused: hudson.remoting.ProxyException: java.io.StreamCorruptedException: Unexpected byte found when reading an object: 0
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:828)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:205)
	at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:76)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadClassDescriptor(RiverUnmarshaller.java:1018)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1355)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:272)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:220)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadCollectionObject(RiverUnmarshaller.java:176)
	at org.jboss.marshalling.river.RiverUnmarshaller.readCollectionData(RiverUnmarshaller.java:850)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:726)
	at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:205)
	at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:41)
	at org.jenkinsci.plugins.workflow.support.pickles.serialization.RiverReader.readPickles(RiverReader.java:176)
	at org.jenkinsci.plugins.workflow.support.pickles.serialization.RiverReader.restorePickles(RiverReader.java:142)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.loadProgramAsync(CpsFlowExecution.java:774)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.onLoad(CpsFlowExecution.java:740)
	at org.jenkinsci.plugins.workflow.job.WorkflowRun.getExecution(WorkflowRun.java:664)
	at org.jenkinsci.plugins.workflow.job.WorkflowRun.onLoad(WorkflowRun.java:526)
	at hudson.model.RunMap.retrieve(RunMap.java:225)
	at hudson.model.RunMap.retrieve(RunMap.java:57)
	at jenkins.model.lazy.AbstractLazyLoadRunMap.load(AbstractLazyLoadRunMap.java:501)
	at jenkins.model.lazy.AbstractLazyLoadRunMap.load(AbstractLazyLoadRunMap.java:483)
	at jenkins.model.lazy.AbstractLazyLoadRunMap.getByNumber(AbstractLazyLoadRunMap.java:381)
	at hudson.model.RunMap.getById(RunMap.java:205)
	at org.jenkinsci.plugins.workflow.job.WorkflowRun$Owner.run(WorkflowRun.java:901)
	at org.jenkinsci.plugins.workflow.job.WorkflowRun$Owner.get(WorkflowRun.java:912)
	at org.jenkinsci.plugins.workflow.flow.FlowExecutionList$1.computeNext(FlowExecutionList.java:65)
	at org.jenkinsci.plugins.workflow.flow.FlowExecutionList$1.computeNext(FlowExecutionList.java:57)
	at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:143)
	at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:138)
	at org.jenkinsci.plugins.workflow.flow.FlowExecutionList$ItemListenerImpl.onLoaded(FlowExecutionList.java:178)
	at jenkins.model.Jenkins.<init>(Jenkins.java:1000)
	at hudson.model.Hudson.<init>(Hudson.java:85)
	at hudson.model.Hudson.<init>(Hudson.java:81)
	at hudson.WebAppMain$3.run(WebAppMain.java:233)
Caused: hudson.remoting.ProxyException: java.io.IOException: Failed to load build state
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$3.onSuccess(CpsFlowExecution.java:855)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$3.onSuccess(CpsFlowExecution.java:853)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution$4$1.run(CpsFlowExecution.java:907)
	at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$1.run(CpsVmExecutorService.java:35)
	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:131)
	at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
	at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59)
	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:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Finished: FAILURE

Any chance this could be fixed in a subsequent release before I perform the upgrade in production, or will I have to live with this one-time failure of all my jobs in order to upgrade?

@dwnusbaum
Copy link
Member

@basil Your question has nothing to do with this PR, please use the users mailing list for this kind of question. See the changelog for the workflow-support 3.0 release here.

@basil
Copy link
Member

basil commented Jun 6, 2019

@basil Your question has nothing to do with this PR, please use the users mailing list for this kind of question. See the changelog for the workflow-support 3.0 release here.

Got it, sorry for the spam. I thought this might have been caused by the robustness fixes, but I now see that was mistaken. Thanks for the pointer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants