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

Role Strategy 2.3 cause poor UI performance due to authorities checks (regression in 2.3.0)

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • role-strategy-plugin
    • Centos 7.2, OpenJDK 1.8.0.91, Jenkins 2.8, Active Directory plugin 1.47, Role Strategy 2.3

      Hello, we recently updated the Role Strategy plugin to 2.3 and after the restart Jenkins UI performance became extremely slow. We isolated the issue to using Active Directory groups in our roles, when we switched to explicitly using users the issue went away.

      When we downgraded the version of Role Strategy to 2.2 the issue also went way.

          [JENKINS-35515] Role Strategy 2.3 cause poor UI performance due to authorities checks (regression in 2.3.0)

          Oleg Nenashev added a comment -

          sschuberth
          Sorry, seems I'm lost in several similar issues. Anyway I'm going to create a pull request for this stacktrace

          Oleg Nenashev added a comment - sschuberth Sorry, seems I'm lost in several similar issues. Anyway I'm going to create a pull request for this stacktrace

          Code changed in jenkins
          User: Oleg Nenashev
          Path:
          src/main/java/com/michelin/cio/hudson/plugins/rolestrategy/RoleMap.java
          src/main/java/org/jenkinsci/plugins/rolestrategy/Settings.java
          src/test/java/org/jenkinsci/plugins/rolestrategy/UserAuthoritiesAsRolesTest.java
          http://jenkins-ci.org/commit/role-strategy-plugin/fe8a518169778bc930e230151abffe8e66e78066
          Log:
          JENKINS-35515 - Fix the performance issue (regression in 2.3.0) (#18)

          • JENKINS-35515 - Disable user authorities handling by deefault, allow tweaking cache settings.

          This change should solve the reported performance issues.
          https://issues.jenkins-ci.org/browse/JENKINS-35515

          • Fixed the copy-paste error in the test suite

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: src/main/java/com/michelin/cio/hudson/plugins/rolestrategy/RoleMap.java src/main/java/org/jenkinsci/plugins/rolestrategy/Settings.java src/test/java/org/jenkinsci/plugins/rolestrategy/UserAuthoritiesAsRolesTest.java http://jenkins-ci.org/commit/role-strategy-plugin/fe8a518169778bc930e230151abffe8e66e78066 Log: JENKINS-35515 - Fix the performance issue (regression in 2.3.0) (#18) JENKINS-35515 - Disable user authorities handling by deefault, allow tweaking cache settings. This change should solve the reported performance issues. https://issues.jenkins-ci.org/browse/JENKINS-35515 JENKINS-35515 - Fix typo Fixed the copy-paste error in the test suite

          Code changed in jenkins
          User: Oleg Nenashev
          Path:
          src/main/java/org/jenkinsci/plugins/rolestrategy/Settings.java
          http://jenkins-ci.org/commit/role-strategy-plugin/4ca0ddc4d67d7a23ba41f4a28416f2eaf1333dc7
          Log:
          JENKINS-35515 - Fix typo in the system property name

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: src/main/java/org/jenkinsci/plugins/rolestrategy/Settings.java http://jenkins-ci.org/commit/role-strategy-plugin/4ca0ddc4d67d7a23ba41f4a28416f2eaf1333dc7 Log: JENKINS-35515 - Fix typo in the system property name

          Oleg Nenashev added a comment -

          The fix has been released as role-strategy:2.3.2

          Oleg Nenashev added a comment - The fix has been released as role-strategy:2.3.2

          There seems to be a problem with the release - when I look at Jenkins --> Plugin Manager, it shows release "2.3.1" (not .2) as the number of the available upgrade.

          Matthew Webber added a comment - There seems to be a problem with the release - when I look at Jenkins --> Plugin Manager, it shows release "2.3.1" (not .2) as the number of the available upgrade.

          We have also had performance problems with Jenkins' WebUI recently, and I wonder if it could be this problem. We don't use AD, but we do use CAS for authentication. Can the performance regression also occur there?

          Matthew Webber added a comment - We have also had performance problems with Jenkins' WebUI recently, and I wonder if it could be this problem. We don't use AD, but we do use CAS for authentication. Can the performance regression also occur there?

          Oleg Nenashev added a comment -

          mwebber
          It takes some time to propagate changes in OSS update centers to all mirrors.
          But the release is in place: http://updates.jenkins-ci.org/download/plugins/role-strategy/2.3.2/role-strategy.hpi

          Regarding CAS it may be also a case. Caching approach in 2.3.0 is not perfect, first load always causes a delay

          Oleg Nenashev added a comment - mwebber It takes some time to propagate changes in OSS update centers to all mirrors. But the release is in place: http://updates.jenkins-ci.org/download/plugins/role-strategy/2.3.2/role-strategy.hpi Regarding CAS it may be also a case. Caching approach in 2.3.0 is not perfect, first load always causes a delay

          I can now install 2.3.2 from the mirrors, and it seems to have improved the WebUI performance (we are using CAS authentication).

          Thanks for the very quick response!

          Matthew Webber added a comment - I can now install 2.3.2 from the mirrors, and it seems to have improved the WebUI performance (we are using CAS authentication). Thanks for the very quick response!

          Oleg Nenashev added a comment -

          Yep, 2.3.2 should just restore 2.2.0 performance for all cases by default.
          It does not mean that I'm happy about 2.2.0 performance

          Oleg Nenashev added a comment - Yep, 2.3.2 should just restore 2.2.0 performance for all cases by default. It does not mean that I'm happy about 2.2.0 performance

          I want to mention that I still see a performance drop in using 2.2.0 vs 2.3.2 with default settings. It is about 7 seconds load time vs. 3 seconds!

          My setup has ~1000 Jobs, defining ~ 70 project roles linked mostly 1:1 to LDAP_GROUPS.

          Andreas Mandel added a comment - I want to mention that I still see a performance drop in using 2.2.0 vs 2.3.2 with default settings. It is about 7 seconds load time vs. 3 seconds! My setup has ~1000 Jobs, defining ~ 70 project roles linked mostly 1:1 to LDAP_GROUPS.

            oleg_nenashev Oleg Nenashev
            reillyprocentive Reilly Brogan
            Votes:
            1 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: