-
Bug
-
Resolution: Fixed
-
Low
-
3.8.4, 3.9.4
-
Severity 2 - Major
-
37
-
Summary
While loading CustomFields values for SLA fields getValueFromIssue() method flushes EagerLoadingOfBizCustomFieldPersister cache (it's used by whole Jira) for each SLA cache miss.
Taking into account JSDSERVER-5681, that makes non-SD issues reindex also slow, since we do extra SQL calls.
Environment
- Jira Core
- Jira ServiceDesk
- Some number (50+) of Service Desk SLA CF
- Large number (200+) of non Service Desk CF
Steps to Reproduce
- Enable SQL logging and set com.atlassian.servicedesk.cache.sla.value to DEBUG
- Create non Service Desk issue
- Check logs
Expected Results
While loading CustomFields values EagerLoadingOfBizCustomFieldPersister is not flushed.
Actual Results
- you can see that during creating new KAN-8 (non-SD) issue, it's loading SLA value and also data from DB
2018-03-08 17:15:36,645 http-nio-1762-exec-8 DEBUG admin 1035x464x1 hckbm2 0:0:0:0:0:0:0:1 /secure/QuickCreateIssue.jspa [c.a.s.cache.sla.value] For custom field id 'customfield_10423' for issue 'KAN-8' returning SLA value: null ... 2018-03-08 17:15:36,667 http-nio-1762-exec-8 DEBUG admin 1035x464x1 hckbm2 0:0:0:0:0:0:0:1 /secure/QuickCreateIssue.jspa [c.a.s.cache.sla.value] For custom field id 'customfield_10422' for issue 'KAN-8' returning SLA value: null
- Issue reindex time increases
- Large number of SQL request to DB
Notes
- loadSLAValue() method flushes EagerLoadingOfBizCustomFieldPersister cache and then load all CF values from DB, example SQL:
SELECT ID, ISSUE, CUSTOMFIELD, UPDATED, PARENTKEY, STRINGVALUE, NUMBERVALUE, TEXTVALUE, DATEVALUE, VALUETYPE FROM customfieldvalue WHERE ISSUE='1319406' ORDER BY UPDATED ASC, ID ASC
- That means that potentially method do extra DB call for each SLA field, making reindexing slow.
- Taking into account
JSDSERVER-5681, that makes non-SD issues reindex also slow, since we do extra SQL calls (~ SLA CF) - So problem is multiplication of NumberOfIssues * NumberOfSLA * CostOfSQL
Workaround
None
- is related to
-
JSDSERVER-5436 Retrieving Issue SLAs can Causes Contention with Cluster Lock
- Closed
-
JRASERVER-66890 JIRA performance is impacted by slow queries pulling data from the customfieldvalue table
- Closed
-
JSDSERVER-5681 Non-optimal computation of SLA values in addDocumentFields() method
- Closed
-
JSMDC-1824 Loading...
- relates to
-
JSDSERVER-6043 Issue update/create is slow due to SLA indexing takes a long time
- Closed
- mentioned in
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...