Uploaded image for project: 'Jira Data Center'
  1. Jira Data Center
  2. JRASERVER-62242

Updating of Field Layouts is an expensive process

XMLWordPrintable

      NOTE: This bug report is for JIRA Server. Using JIRA Cloud? See the corresponding bug report.

      Summary

      Updating of FieldLayouts is expensive because whenever any change to FieldLayout happens there has to be a synchronized opperation done that removes all FieldLayoutItems for that FieldLayout and creates them all again (This is an order of magnitude of a number of custom fields so for large instances with thousands of custom fields editing FieldLayouts can become a major problem). Even if we change description of only a single FieldLayoutItem all items need to be recreated..

      Environment

      • Large number of custom fields: 1500+
      • Large number fieldlayout (Field Configuration):
        SQL> select count(1) from fieldlayout; 
        576 
        
        SQL> select count(1) from fieldlayoutitem; 
        1355666
        

      Steps to Reproduce

      Using a very large instance, edit a field configuration.

      Expected Results

      JIRA does not remove all FieldLayoutItems for that FieldLayout and creates them all again.

      Actual Results

      JIRA executes a very high amount of SQL, as it removes all FieldLayoutItems for that FieldLayout and creates them all again. SQL similar to:

      INSERT INTO public.fieldlayoutitem (ID, FIELDLAYOUT, FIELDIDENTIFIER, DESCRIPTION, VERTICALPOSITION, ISHIDDEN, ISREQUIRED, RENDERERTYPE) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
      

              Unassigned Unassigned
              dcurrie@atlassian.com Dave C
              Votes:
              13 Vote for this issue
              Watchers:
              18 Start watching this issue

                Created:
                Updated: