-
Bug
-
Resolution: Fixed
-
Highest
-
8.14.0
-
8.14
-
28
-
Severity 1 - Critical
-
262
-
Issue Summary
User mentions and assignee lookup are slow with Jira 8.14+/JSM 4.14+. Performance regression started after Jira upgrade from the previous LTS 8.13 to 8.14 release and this was caused by the internal upgrade of the Embedded Crowd to 4.2.0+ version.
EmbCrowd requests create an additional load on DB since UserDao method doesn't have a specific cache.
Environments Affected
Jira Software - all versions between 8.14 and 8.19.0
Jira Service Management - all versions between 4.14 and 4.19.0
Steps to Reproduce
- Setup Jira with large user base (50k+)
- Created new Jira project and issue
- @ mention user in the issue comment
Expected Results
@ mention user lookup result returns instantaneously, especially the one that user have searched recently/repeatedly
Actual Results
@ mention user lookup takes a substantial amount of time (few minutes) to return the list of matching users
Investigation
No error from logs.
Capturing the SQL logs in local testing, we noticed that Jira is querying every user:
- every internal user against internal directory once e.g:
2021-01-22 21:16:57,072+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 1ms "SELECT user_name FROM public.cwd_user WHERE (lower_user_name = 'admin' ) AND (directory_id = '1' ) ORDER BY lower_user_name" 2021-01-22 21:16:57,072+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 1ms Connection returned. borrowed : 0 2021-01-22 21:16:57,072+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 0ms Connection taken. borrowed : 1
- every LDAP user against the internal directory and every LDAP integrated with Jira e.g:
2021-01-22 21:16:57,097+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 1ms "SELECT user_name FROM public.cwd_user WHERE (lower_user_name = 'jack' ) AND (directory_id = '1' ) ORDER BY lower_user_name" 2021-01-22 21:16:57,097+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 1ms Connection returned. borrowed : 0 2021-01-22 21:16:57,097+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 0ms Connection taken. borrowed : 1 2021-01-22 21:16:57,098+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 1ms "SELECT user_name FROM public.cwd_user WHERE (lower_user_name = 'jack' ) AND (directory_id = '10000' ) ORDER BY lower_user_name" 2021-01-22 21:16:57,098+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 1ms Connection returned. borrowed : 0 2021-01-22 21:16:57,099+1100 http-nio-48140-exec-9 admin 1276x1590x1 12f88sa /rest/internal/2/user/mention/search 0ms Connection taken. borrowed : 1
This same is not observed with similar setup in Jira 8.13.
With the above findings, a lot of queries are hitting the Jira database especially if many users are sync from LDAP and/or there are multiple LDAPs integrated with Jira.
The same amount of queries are incurred, despite repeatedly @ mentioning the same user in the same issue.
Workaround
Reduce the users synchronized from the external directory as Jira may scan the whole database table in some corner cases. Doing this will also help with performance improvements in other areas.
Reducing the number of users synchronized from LDAP to JIRA applications
- has a regression in
-
JRASERVER-73406 User are not searchable on assignee field when assigned to a shared group (assignee search dropdown does not return any result)
- Gathering Impact
-
JRASERVER-73044 The status property key jira.permission.assignable.group is ignored
- Gathering Impact
- is related to
-
JRASERVER-73023 Server Error while assigning Issue or performing mentioned Search in comment
- Closed
-
JRASERVER-72581 User Picker Dropdown takes an excessive amount of time to load when there are thousands of users in Jira and up to 49 users in the Assignable User permission
- Closed
-
JRASERVER-74911 User/group cache not fully replicated on node start.
- Closed
-
JSWSERVER-20336 Searching and Mentioning users may cause performance issues and high CPU load
- Closed
-
JRASERVER-60532 Slow query in user picker : DefaultUserPickerSearchService
- Closed
- mentioned in
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
- relates to
-
GHS-211522 Loading...
-
PSR-634 Loading...
-
RAID-2363 Loading...
-
UCACHE-18 Loading...