Browse user is slow
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
Problem
Slow performance is observed when user is browsing users in attempt to populate 'Request participants' field.
Diagnosis
Environment
JIRA 7.5.4 with JSD 3.8.5
Database : mySQL 5.7.11
81684 users in JIRA internal directory (no external LDAP)
Diagnostic Steps
With SQL logging enabled in JIRA, we observed a single search yields around 2968 searches against cwd_users database table, example:
atlassian-jira.log
1
2018-05-01 16:12:46,837 http-nio-8080-exec-25 admin 972x326x4 admin /rest/servicedesk/1/servicedesk/sd-user-search/participants 1414ms "SELECT ID, directory_id, user_name, lower_user_name, active, created_date, updated_date, first_name, lower_first_name, last_name, lower_last_name, display_name, lower_display_name, email_address, lower_email_address, CREDENTIAL, deleted_externally, EXTERNAL_ID FROM cwd_user WHERE (directory_id='1') AND (lower_user_name IN ('<500_users...>) )"
Cause
The SQL queries against cwd_user database table were invoked when LazyOfBizUserCache is used.
The following log message, confirmed the use of LazyOfBizUserCache:
atlassian-jira.log
1
2018-04-12 22:16:17,027 JIRA-Bootstrap INFO [c.a.j.c.embedded.ofbiz.OfBizUserDao] Using lazy user cache
Solution
Resolution
Update JIRA to use full user cache:
Update
<JIRA_HOME>/jira-config.properties
(create the file if it's not found) with the following:jira.fullUserCache=true
Restart JIRA application
Was this helpful?