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

Paging not usable with large number of historical builds

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Critical
    • Resolution: Fixed
    • Labels:
      None
    • Environment:
      Jenkins 1.642.3, delivery-pipeline-plugin 0.9.11
    • Similar Issues:

      Description

      It seems that paging mechanism (JENKINS-28918) introduced regression in the situation where the first job in the pipeline has many historical builds.

      With paging enabled `Pipeline.createPipelineLatest()` creates a `Pipeline` instance for [every](https://github.com/Diabol/delivery-pipeline-plugin/commit/072343839463fe97a5b09e3ac47ef9f9433b239b#diff-abd99f83e18e7913a8ea3929339bc3a2R228) historical build (even if just a few will be displayed in the pipeline view). Before that change (or with paging disabled) only instances required to display are created.

      From the profiler output (see screenshots) the amount of processing time spent in `createPipelineLatest()` increased from ~10% to ~50% for just 20 builds. For projects with 300+ historical builds number of processing treats makes Jenkins irresponsible very quickly.

      Looking at the implementation currently not displayed builds are removed at the end in `Component.getPipelines()`. It would be probably required to pass paging information the Pipeline class to create only Pipeline instances that will be used in the view.

      Suresh Kumar WDYT?

        Attachments

          Activity

          Hide
          pskumar448 Suresh Kumar added a comment -

          Yes what you said is correct, probably as you said we have to pass pagination information to pipeline class.

          -Suresh

          Show
          pskumar448 Suresh Kumar added a comment - Yes what you said is correct, probably as you said we have to pass pagination information to pipeline class. -Suresh
          Hide
          tommysdk Tommy Tynjä added a comment -

          Can we add a reproducing test case for this issue to avoid regression issues in the future?

          Show
          tommysdk Tommy Tynjä added a comment - Can we add a reproducing test case for this issue to avoid regression issues in the future?
          Hide
          tommysdk Tommy Tynjä added a comment -

          Thank you Marcin Zajączkowski for reporting this issue. Appreciated the profiling information!

          Show
          tommysdk Tommy Tynjä added a comment - Thank you Marcin Zajączkowski for reporting this issue. Appreciated the profiling information!
          Hide
          tommysdk Tommy Tynjä added a comment -

          Merged to master: 618ec249d51632396c9983fd77ba21662fe869a7
          Will be part of next release.

          Suresh Kumar Olga Maciaszek-Sharma Marcin Zajączkowski Thank you for your great work and collaboration on addressing this issue!

          Show
          tommysdk Tommy Tynjä added a comment - Merged to master: 618ec249d51632396c9983fd77ba21662fe869a7 Will be part of next release. Suresh Kumar Olga Maciaszek-Sharma Marcin Zajączkowski Thank you for your great work and collaboration on addressing this issue!

            People

            • Assignee:
              pskumar448 Suresh Kumar
              Reporter:
              emszpak Marcin Zajączkowski
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: