Details

    • Type: Bug
    • Status: Reopened (View Workflow)
    • Priority: Critical
    • Resolution: Unresolved
    • Component/s: blueocean-plugin
    • Labels:
      None
    • Environment:
      Firefox 52.1.2 on OS X
    • Epic Link:
    • Sprint:
      Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2, Blue Ocean - Candidates
    • Similar Issues:

      Description

      https://ci.jenkins.io/blue/organizations/jenkins/Core%2Fjenkins/pr takes 30 seconds to load

      Activity pages similarly take forever.

        Attachments

          Activity

          danielbeck Daniel Beck created issue -
          danielbeck Daniel Beck made changes -
          Field Original Value New Value
          Summary Activity tab takes forever to load PR tab takes forever to load
          danielbeck Daniel Beck made changes -
          Hide
          danielbeck Daniel Beck added a comment -

          Attached: Me first navigating from home page to Core/jenkins activity page, then to PRs. Takes 1.2 minutes.

          Show
          danielbeck Daniel Beck added a comment - Attached: Me first navigating from home page to Core/jenkins activity page, then to PRs. Takes 1.2 minutes.
          Hide
          vivek Vivek Pandey added a comment -

          Daniel Beck Please open another ticket for activity perf issue.

          Show
          vivek Vivek Pandey added a comment - Daniel Beck Please open another ticket for activity perf issue.
          jamesdumay James Dumay made changes -
          Priority Minor [ 4 ] Blocker [ 1 ]
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1 [ 336 ]
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Assignee Vivek Pandey [ vivek ]
          jamesdumay James Dumay made changes -
          Epic Link JENKINS-37957 [ 174099 ]
          vivek Vivek Pandey made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          Hide
          vivek Vivek Pandey added a comment -

          PR https://github.com/jenkinsci/blueocean-plugin/pull/1149 merged to release branch. It will be in next release, most likely 1.1.2.

          Show
          vivek Vivek Pandey added a comment - PR https://github.com/jenkinsci/blueocean-plugin/pull/1149  merged to release branch. It will be in next release, most likely 1.1.2.
          vivek Vivek Pandey made changes -
          Status In Progress [ 3 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          jamesdumay James Dumay made changes -
          Resolution Fixed [ 1 ]
          Status Resolved [ 5 ] Reopened [ 4 ]
          Hide
          jamesdumay James Dumay added a comment - - edited

          Vivek Pandey as discussed we need to make io.jenkins.blueocean.rest.impl.pipeline.PipelineJobFilters#isPullRequest use SCMHeadCategory to improve the performance of this lookup.

          Any ideas on how we can do that, Stephen Connolly?

          Show
          jamesdumay James Dumay added a comment - - edited Vivek Pandey as discussed we need to make io.jenkins.blueocean.rest.impl.pipeline.PipelineJobFilters#isPullRequest use SCMHeadCategory to improve the performance of this lookup. Any ideas on how we can do that, Stephen Connolly ?
          jamesdumay James Dumay made changes -
          Priority Blocker [ 1 ] Critical [ 2 ]
          Hide
          stephenconnolly Stephen Connolly added a comment -

          Currently you are using SCMHead.HeadByItem.findHead(item) instanceof ChangeRequestSCMHead which is reasonable, but not the intent of the API.

          The intent of the API is that you would ask the item's parent SCMSource for the SCMHeadCategory though I should point out that if the code in question is the hot path, that check would be more expensive in terms of CPU.

          You probably need to use a profiler and see where the code is hot.

          To use categories correctly, you need to ask the relevant SCMSource instances for the categories they are providing. Once you have all the potential categories, you then use SCMHeadCategory.collect to aggregate them... Each of those aggregate categories should get its own "tab" (you can consider treating the "uncategorized" category specially).

          Then for each tab, you just ask it's category if the SCMHead is a SCMHeadCategory.isMatch(SCMHead)

           

          Show
          stephenconnolly Stephen Connolly added a comment - Currently you are using SCMHead.HeadByItem.findHead(item) instanceof ChangeRequestSCMHead which is reasonable, but not the intent of the API. The intent of the API is that you would ask the item's parent SCMSource for the SCMHeadCategory though I should point out that if the code in question is the hot path, that check would be more expensive in terms of CPU. You probably need to use a profiler and see where the code is hot. To use categories correctly, you need to ask the relevant SCMSource instances for the categories they are providing. Once you have all the potential categories, you then use SCMHeadCategory.collect  to aggregate them... Each of those aggregate categories should get its own "tab" (you can consider treating the "uncategorized" category specially). Then for each tab, you just ask it's category if the SCMHead is a SCMHeadCategory.isMatch(SCMHead)  
          Hide
          stephenconnolly Stephen Connolly added a comment -

          If SCMHead.HeadByItem.findHead(Item) is a hot code path then there are some caching optimizations I could apply, but a brief code inspection suggests that it should not be the hot path for you.

          Show
          stephenconnolly Stephen Connolly added a comment - If SCMHead.HeadByItem.findHead(Item) is a hot code path  then there are some caching optimizations I could apply, but a brief code inspection suggests that it should not be the hot path for you.
          vivek Vivek Pandey made changes -
          Attachment image-2017-06-21-21-02-36-981.png [ 38574 ]
          Hide
          vivek Vivek Pandey added a comment - - edited

          Stephen Connolly Classic uses `SCMHeadCategory` and renders it relatively quickly compared to blueocean. See https://ci.jenkins.io/job/Core/job/jenkins/view/change-requests/ vs https://ci.jenkins.io/blue/organizations/jenkins/Core%2Fjenkins/pr. That prompted us to think this might help us. I tried to run profiler but could not get consistent hot spot as creating PR based data set is not easy.

           

          In one of the profiler test this line came up, https://github.com/jenkinsci/blueocean-plugin/blob/4f595b217795096240fff6c4bbd8af1921282b18/blueocean-pipeline-api-impl/src/main/java/io/jenkins/blueocean/rest/impl/pipeline/BranchImpl.java#L54. But again it was based on the data set I was using which was not big enough to trigger proper hot spot.

           

           

          Show
          vivek Vivek Pandey added a comment - - edited Stephen Connolly  Classic uses `SCMHeadCategory` and renders it relatively quickly compared to blueocean. See https://ci.jenkins.io/job/Core/job/jenkins/view/change-requests/  vs https://ci.jenkins.io/blue/organizations/jenkins/Core%2Fjenkins/pr . That prompted us to think this might help us. I tried to run profiler but could not get consistent hot spot as creating PR based data set is not easy.   In one of the profiler test this line came up, https://github.com/jenkinsci/blueocean-plugin/blob/4f595b217795096240fff6c4bbd8af1921282b18/blueocean-pipeline-api-impl/src/main/java/io/jenkins/blueocean/rest/impl/pipeline/BranchImpl.java#L54.  But again it was based on the data set I was using which was not big enough to trigger proper hot spot.    
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1 [ 336 ]
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta2 [ 341 ]
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Assignee Vivek Pandey [ vivek ] James Dumay [ jamesdumay ]
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta2 [ 341 ] Blue Ocean 1.2-beta1 [ 336 ]
          jamesdumay James Dumay made changes -
          Rank Ranked lower
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1 [ 336 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2 [ 336, 341 ]
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          Hide
          jamesdumay James Dumay added a comment -

          Confirmed that this is still an issue

          Vivek Pandey Stephen Connolly did I see correctly that in the new branch source that we've got a more efficient way of searching for branches that are PRs?

          Show
          jamesdumay James Dumay added a comment - Confirmed that this is still an issue Vivek Pandey Stephen Connolly did I see correctly that in the new branch source that we've got a more efficient way of searching for branches that are PRs?
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2 [ 336, 341 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta3 [ 336, 341, 346 ]
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta3 [ 336, 341, 346 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4 [ 336, 341, 361 ]
          jamesdumay James Dumay made changes -
          Assignee James Dumay [ jamesdumay ]
          jamesdumay James Dumay made changes -
          Assignee Ivan Meredith [ imeredith ]
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4 [ 336, 341, 361 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2-beta5 [ 336, 341, 361, 376 ]
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Assignee Ivan Meredith [ imeredith ] Vivek Pandey [ vivek ]
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2 [ 336, 341, 361, 376 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2, Blue Ocean 1.3 - beta 1 [ 336, 341, 361, 376, 386 ]
          Hide
          michaelneale Michael Neale added a comment -

          can anyone confirm if this is helped by 1.2/newer releases of late? I tried with link above and it seemed "ok" but there are many other variables in my link speed. 

          Show
          michaelneale Michael Neale added a comment - can anyone confirm if this is helped by 1.2/newer releases of late? I tried with link above and it seemed "ok" but there are many other variables in my link speed. 
          michaelneale Michael Neale made changes -
          Sprint Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2, Blue Ocean 1.3 - beta 1 [ 336, 341, 361, 376, 386 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2 [ 336, 341, 361, 376 ]
          michaelneale Michael Neale made changes -
          Sprint Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2 [ 336, 341, 361, 376 ] Blue Ocean 1.3 - candidates, Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2 [ 326, 336, 341, 361, 376 ]
          michaelneale Michael Neale made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.4 - candidates, Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2 [ 326, 336, 341, 361, 376 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2, Blue Ocean 1.4 - beta 2 [ 336, 341, 361, 376, 416 ]
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Rank Ranked higher
          jamesdumay James Dumay made changes -
          Sprint Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2, Blue Ocean 1.4 - beta 3 [ 336, 341, 361, 376, 416 ] Blue Ocean 1.2-beta1, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta4, Blue Ocean 1.2, Blue Ocean 1.4 - beta 4 [ 336, 341, 361, 376, 441 ]
          Hide
          dbsanfte David Sanftenberg added a comment -

          I ran into this recently and the issue was actually failing connections to Sonarqube. Any plugins you have installed may be calling APIs for the PR builds when you load the PR tab. If those calls stall or get connection timeouts, they will block the loading of the page view. This is surely a bug since the page view should not be blocked like this, but can be resolved if you resolve the underlying problems connecting to e.g. Sonarqube.

          Show
          dbsanfte David Sanftenberg added a comment - I ran into this recently and the issue was actually failing connections to Sonarqube. Any plugins you have installed may be calling APIs for the PR builds when you load the PR tab. If those calls stall or get connection timeouts, they will block the loading of the page view. This is surely a bug since the page view should not be blocked like this, but can be resolved if you resolve the underlying problems connecting to e.g. Sonarqube.

            People

            • Assignee:
              vivek Vivek Pandey
              Reporter:
              danielbeck Daniel Beck
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated: