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

NPE in CPS VM thread at WorkflowRun$GraphL.onNewHead

    XMLWordPrintable

    Details

    • Sprint:
      Pipeline - April 2018
    • Similar Issues:

      Description

      I have 2 jobs stuck in the build queue waiting, jobs are apparently waiting for 2 other jobs to complete but the nodes executors are free. I don't if these NPE can cause this behavior but they don't look right anyway.

      Feb 21, 2018 8:38:55 PM org.jenkinsci.plugins.workflow.cps.CpsFlowExecution onLoad
      WARNING: Pipeline state not properly persisted, cannot resume job/ice/job/3.7/221/
      Feb 21, 2018 8:38:55 PM org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService reportProblem
      WARNING: Unexpected exception in CPS VM thread: CpsFlowExecution[Owner[ice/3.7/221:ice/3.7 #221]]
      java.lang.NullPointerException
      at org.jenkinsci.plugins.workflow.job.WorkflowRun$GraphL.onNewHead(WorkflowRun.java:997)
      at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.notifyListeners(CpsFlowExecution.java:1368)
      at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$3.run(CpsThreadGroup.java:412)
      at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$1.run(CpsVmExecutorService.java:35)
      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:1149)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      at java.lang.Thread.run(Thread.java:748)
      
      Feb 21, 2018 8:38:55 PM org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService reportProblem
      WARNING: Unexpected exception in CPS VM thread: CpsFlowExecution[Owner[ice/3.7/221:ice/3.7 #221]]
      java.lang.NullPointerException
      at org.jenkinsci.plugins.workflow.job.WorkflowRun$GraphL.onNewHead(WorkflowRun.java:997)
      at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.notifyListeners(CpsFlowExecution.java:1368)
      at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$3.run(CpsThreadGroup.java:412)
      at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$1.run(CpsVmExecutorService.java:35)
      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:1149)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      at java.lang.Thread.run(Thread.java:748)
      
      

        Attachments

        1. build.xml.gz
          3 kB
        2. build.xml.gz
          3 kB
        3. flowNodeStore.xml.gz
          53 kB
        4. flowNodeStore.xml.gz
          53 kB
        5. jenkins.log.gz
          257 kB
        6. jenkins.log.gz
          257 kB
        7. workflow-cps.hpi
          540 kB
        8. workflow-job.hpi
          110 kB

          Issue Links

            Activity

            Hide
            svanoort Sam Van Oort added a comment -

            Resolved as of workflow-cps 2.47 and workflow-job 2.18

            Show
            svanoort Sam Van Oort added a comment - Resolved as of workflow-cps 2.47 and workflow-job 2.18
            Hide
            svanoort Sam Van Oort added a comment -

            At least one report still in JENKINS-50199

            Show
            svanoort Sam Van Oort added a comment - At least one report still in JENKINS-50199
            Hide
            bentoi bentoi added a comment -

            I no longer see the NullPointerException with the latest plugins however I'm seeing some failures when trying to load the "FlowNodes" 

            Apr 25, 2018 2:21:04 AM org.jenkinsci.plugins.workflow.cps.CpsFlowExecution initializeStorage
            WARNING: Tried to load head FlowNodes for execution Owner[ice/3.7/264:ice/3.7 #264] but FlowNode was not found in storage for head id:FlowNodeId 1:1858
            Apr 25, 2018 2:21:04 AM org.jenkinsci.plugins.workflow.cps.CpsFlowExecution rebuildEmptyGraph
            WARNING: Failed to load pipeline heads, so faking some up for execution CpsFlowExecution[Owner[ice/3.7/264:ice/3.7 #264]]
            Apr 25, 2018 2:21:04 AM org.jenkinsci.plugins.workflow.cps.CpsFlowExecution onLoad
            WARNING: Completed flow without FlowEndNode: CpsFlowExecution[Owner[ice/3.7/264:ice/3.7 #264]] heads:1859::1859:org.jenkinsci.plugins.workflow.graph.FlowStartNode[id=1860]

            These failures are also mentioned on JENKINS-50199. Let me know if you need any additional information related to these.

            Show
            bentoi bentoi added a comment - I no longer see the NullPointerException with the latest plugins however I'm seeing some failures when trying to load the "FlowNodes"  Apr 25, 2018 2:21:04 AM org.jenkinsci.plugins.workflow.cps.CpsFlowExecution initializeStorage WARNING: Tried to load head FlowNodes for execution Owner[ice/3.7/264:ice/3.7 #264] but FlowNode was not found in storage for head id:FlowNodeId 1:1858 Apr 25, 2018 2:21:04 AM org.jenkinsci.plugins.workflow.cps.CpsFlowExecution rebuildEmptyGraph WARNING: Failed to load pipeline heads, so faking some up for execution CpsFlowExecution[Owner[ice/3.7/264:ice/3.7 #264]] Apr 25, 2018 2:21:04 AM org.jenkinsci.plugins.workflow.cps.CpsFlowExecution onLoad WARNING: Completed flow without FlowEndNode: CpsFlowExecution[Owner[ice/3.7/264:ice/3.7 #264]] heads:1859::1859:org.jenkinsci.plugins.workflow.graph.FlowStartNode[id=1860] These failures are also mentioned on JENKINS-50199 . Let me know if you need any additional information related to these.
            Hide
            svanoort Sam Van Oort added a comment -

            bentoi Appreciate the update – I think I've got a handle on all of the related issues here and test coverage for it. Just working through a few remaining challenges and then review + human testing.

            Show
            svanoort Sam Van Oort added a comment - bentoi Appreciate the update – I think I've got a handle on all of the related issues here and test coverage for it. Just working through a few remaining challenges and then review + human testing.
            Hide
            svanoort Sam Van Oort added a comment -

            Should be resolved with release of workflow-cps 2.50 and workflow-job 2.21 CC bentoi

            Show
            svanoort Sam Van Oort added a comment - Should be resolved with release of workflow-cps 2.50 and workflow-job 2.21 CC bentoi

              People

              • Assignee:
                svanoort Sam Van Oort
                Reporter:
                bentoi bentoi
              • Votes:
                1 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: