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

Loading pipeline builds is expensive because they have a lot of baggage

      Specifically, CpsFlowExecution holds the loaded scripts, which are potentially large:

      https://github.com/jenkinsci/workflow-cps-plugin/blob/master/src/main/java/org/jenkinsci/plugins/workflow/cps/CpsFlowExecution.java#L239

      And the main script:

      https://github.com/jenkinsci/workflow-cps-plugin/blob/master/src/main/java/org/jenkinsci/plugins/workflow/cps/CpsFlowExecution.java#L233

      We don't need to load these EVERY time we load a build.  We could lazy-load them as needed (should happen once in a blue moon I hope). 

      Reducing the number of times we have to re-persist the build.xml would help even more  though - https://issues.jenkins-ci.org/browse/JENKINS-47174

       

          [JENKINS-47175] Loading pipeline builds is expensive because they have a lot of baggage

          Sam Van Oort added a comment -

          jglick This tracks the issue you'd mentioned with the scripts (though I hope to make that less of an issue by reducing save/re-save cycles for the execution and build). 

          Sam Van Oort added a comment - jglick This tracks the issue you'd mentioned with the scripts (though I hope to make that less of an issue by reducing save/re-save cycles for the execution and build). 

          Sam Van Oort added a comment -

          NVM, I forgot we had an existing issue, heh.

          Sam Van Oort added a comment - NVM, I forgot we had an existing issue, heh.

            svanoort Sam Van Oort
            svanoort Sam Van Oort
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: