-
Bug
-
Resolution: Fixed
-
Highest
-
8.0.0, 8.5.1, 8.13.0
-
8
-
28
-
Severity 3 - Minor
-
160
-
Issue Summary
If a Jira issue screen (Create Issue screen, Edit Issue screen) contains a "Select List (single choice)" custom field verifying the following conditions below, the screen will take a long time to load (for example, 15s-30s):
- the field contains a high number of option (for example 10k)
- a big portion of these options is disabled
Depending on the browser type and version, there will either be a spinning wheel displayed in the UI until the screen loads, or the browser will freeze until the screen loads.
Environment
Not replicable on Jira 7.x.
Replicable on any Jira version from 8.0.0
Steps to replicate
- Install Jira 8.13.0
- Add the the add-on Data Generator for Jira to this Jira installation
- Use the "Generate Metadata" functionality from this add-on create a "Select List (single choice)" custom field containing 10k values
- Create a new Core project
- Edit the edit issue screen used in this project by adding the custom field created by the add-on
- Create a new Jira issue in the project
- Stop Jira
- Log into the Jira DB
- Search for the ID of the custom field in the table customfield
- Once you have it, use this ID to run the following UPDATE query, in order to set the 10k option values to disabled
update customfieldoption set disabled = 'Y' where customfield = <CUSTOM_FIELD_ID>;
- Restart Jira, for these DB changes to be effective
- Open the Jira issue created earlier in the Core project
- Click on the edit button
Actual results
A spinning wheel is shown in the UI for 15 seconds an eventually the "Edit issue screen" appears
Jira_813_CustomField_10kOptions_AllDisabled.mov
Expected results
The "Edit issue" screen should load within less than 1 second, as it is the case with Jira 7.13.0:
Jira_713_CustomField_10kOptions_AllDisabled.mov
Note on fix
Since the problem is caused by slow parsing of HTML string response (with a massive amount of whitespaces), we switched to DOMParser API to parse it before passing it further. This way the faulty line with `trim` method is omitted.
Also, we spotted the same problem on the issue view page (UI was stalled for ~15 seconds). We fixed it too.
Workaround
The workaround consists in:
- either reducing the number of disabled options from the select list custom field
- or removing the problematic select list custom field from the screen configuration
- is related to
-
JRASERVER-72810 Browser performance degraded when customfield has a large number of customfieldoption.
- Gathering Impact
- is cloned by
-
MNSTR-4992 Loading...
- mentioned in
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...