[KULRICE-7517] Improve performance of RoleService by not loading membership information for the RoleBo for nearly every method call Created: 20/Jun/12  Updated: 20/Jul/12  Resolved: 20/Jul/12

Status: Closed
Project: Kuali Rice Development
Component/s: Performance
Affects Version/s: None
Fix Version/s: 2.1.2
Security Level: Public (Public: Anyone can view)

Type: Improvement Priority: Major
Reporter: James Bennett Assignee: James Bennett
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Similar issues:
KULRICE-13135Remove all membership mappings from GroupBo and RoleBo
KULRICE-8962CloneUtils deepCloneObject Performance Improvement
KULRICE-8849removePrincipalFromRole and getRoleMemberPrincipalId methods very slow
KULRICE-13122Tree group invokes nested property for every node which causes performance issues
KULRICE-8847Role lookups slow when there are over 200 roles
KULRICE-3869processAfterPost not called after every post
KULRICE-7254improve RoleServiceBase.convertQualifierKeys(..) performance
KULRICE-12325RoleService does not properly populate delegates for nested role memberships
KULRICE-5100StyleServiceImpl.getStyle should perform caching of styles
KULRICE-6722RoleService assign methods don't check for inactive role members correctly
KAI Review Status: Not Required
KTI Review Status: Not Required


The RoleServiceImpl and RoleServiceBase classes use a method called getRoleBo excessively which fetches the RoleBo from the database many times during any role check. The RoleBo fetches all of the membership information when it is fetched from the DB even though this information isn't used in any of the logic in the RoleServiceImpl or RoleServiceBase. The KFS implementation at IU has a role which has 4000+ people in it so fetching the membership information adds 2500ms or so to each call to fetch the RoleBo. This adds around 15s of time to any role or permission check which happens to involve that role which is far too long. We have created a "RoleBoLite" which is the same as the RoleBo without the membership information and changing the RoleServiceImpl/RoleServiceBase to use this object instead of the full BO took the 15 second permission check down to 90ms which is more in line with how the service needs to perform.

Comment by Eric Westfall [ 20/Jul/12 ]

James, can this one be closed out since you already did work here?

Generated at Sat May 30 16:16:39 CDT 2020 using JIRA 6.1.5#6160-sha1:a61a0fc278117a0da0ec9b89167b8f29b6afdab2.