Kuali Rice Development
  1. Kuali Rice Development
  2. KULRICE-8836

Person maintenance screen loading very slowly when the person has a lot of roles

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 2.1.2
    • Fix Version/s: 2.1.3
    • Component/s: Performance
    • Security Level: Public (Public: Anyone can view)
    • Labels:
      None
    • Similar issues:
      KULRICE-13136Performance issues routing person maintenance document when user is a member of large roles
      KULRICE-7103Person Inquiry Screen doesn't load past the memberships section
      KULRICE-4677Person/Group/Role/Permission/Responsibility update screen Save/Submit enhancements
      KULRICE-11045Delegations throws exception when selecting role in Person Maintenance
      KULRICE-11043Person document goes into exception when attempting to deactivate a Person with a single group membership
      KULRICE-9165Person document not displaying role qualifiers
      KULRICE-9199Unable to inactivate roles of type unitHierarchy or unit from person maintenance docs
      KULRICE-7605Person and Role document broken when displaying data with role that has namespace qualifier
      KULRICE-4822fix inconsistencies in person role maintenance
      KULRICE-12367Document search loads person record for each row needlessly.
    • Rice Module:
      KIM
    • Application Requirement:
      KC
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required

      Description

      When a person has a lot of roles which in turn have a lot of members, the person maintenance document for that person takes minutes to load. I am attaching some simulated data for testing. In the data, I created 500 roles and assigned 1500 members to each of those roles. In the real dataset there were more members assigned to each role. Based on my analysis, the issues is with the UiDocumentServiceImpl class in the loadRoleToPersonDoc method. The largest performance hit was when it tried to getRolesForPrincipal(identityManagementPersonDocument.getPrincipalId()). The slowness is because of trying to load all the members for every role. I am not entirely sure why all the members for all the roles are required here but I do see that further down in the loadRoleToPersonDoc method, these members are used to populate the PersonDocumentRole. So if all the members are indeed required then the option to use RoleBoLite to fix this is out? Perhaps a solution like in KULRICE-8415 is required which is a combination of using straight SQL for retrieval and paging through the list of roles?

      The data I have attached is in the form of sql queries that can be sourced into any MySQL database. Please let me know if you would like this data in a different format.

      1. KULRICE.sql.gz
        4.20 MB
        Gayathri Athreya

        Issue Links

          Activity

          Hide
          Gayathri Athreya added a comment -

          Corey, I am waiting for the resolution of 2 other performance issues KULRICE-8849 and KULRICE-8847. I will test all at one go when those are resolved too since there is data overlap. Thanks.

          Show
          Gayathri Athreya added a comment - Corey, I am waiting for the resolution of 2 other performance issues KULRICE-8849 and KULRICE-8847 . I will test all at one go when those are resolved too since there is data overlap. Thanks.
          Hide
          Corey Pedersen (Inactive) added a comment -

          Committed revision 37259. Update after code review and code report changes applied.

          Show
          Corey Pedersen (Inactive) added a comment - Committed revision 37259. Update after code review and code report changes applied.
          Hide
          Gayathri Athreya added a comment -

          This does seem to have improved performance considerably, thanks. I will close this jira once our testers close the main jira.

          Show
          Gayathri Athreya added a comment - This does seem to have improved performance considerably, thanks. I will close this jira once our testers close the main jira.
          Hide
          Geo Thomas (Inactive) added a comment -

          Tested with the super user, who has more than 95 roles. Screen came up in 30 seconds and save & refresh happens within 45 seconds.
          Gayathri, We can resolve this one too.

          Thanks
          Geo

          Show
          Geo Thomas (Inactive) added a comment - Tested with the super user, who has more than 95 roles. Screen came up in 30 seconds and save & refresh happens within 45 seconds. Gayathri, We can resolve this one too. Thanks Geo
          Hide
          Gayathri Athreya added a comment -

          Great, thanks Corey

          Show
          Gayathri Athreya added a comment - Great, thanks Corey

            People

            • Assignee:
              Corey Pedersen (Inactive)
              Reporter:
              Gayathri Athreya
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Structure Helper Panel