Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Custom Fields with global context what type of performance gain

FlightSafetyS
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 10, 2020

what type of performance gain is expected if custom field context is changed from global to project level , lets say on 100 custom fields?

2 answers

2 votes
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 13, 2020

The answer might actually depend on your version of Jira.

For a very very long time (I'm thinking of Jira 2 as the starting point because that's where I started), custom fields were all written into the indices no matter what their content or context.

So, bearing in mind that every field on every issue has a value in the index (even when the field is empty), you can imagine that the code that queries them is not ideal, because it looks at the index like this:

  1. Is there a value there?
  2. If yes, then is the data valid for this project/issuetype?
  3. If it is, then what is it?
  4. Does that value match the question being asked?

Each question in that list imposes load and potentially quite a lot, if you're asking about a lot of issues.  They are all coded such that a response of "no" means "don't ask the following questions".  (For example if Q2 is a "no", the code for Q3 and Q4 won't run)

Until Jira 8.something, the answer to Q1 was always "yes", because even empty fields had "nothing here" entries in the index. 

Q2 was the important one and, as @John Funk says, has an absolutely massive effect.  For global context fields, the answer is always yes, so Jira then has to run the code for questions 3 and 4.  Even when there's nothing there, it still has to execute the "get value and compare" code.

Reducing the context of a field makes a big difference, because it means Jira can stop after a "no" from Q2.

However.  Jira 8.something changed this.  (I'm sorry, I can't remember which it is - 8 upgraded Lucence to a point where it could do this, but I do not know where Jira code began to actually use it)

Jira no longer puts anything in the index for fields that have no context for a project.  This means it now has "no" as an answer for Q1, so that gets a lot faster.

TLDR:  For
* old versions of Jira, your performance gain for localising fields is big and worth doing. 

* Jira 8.something, your performance gain for localising fields is huge and worth doing. (and probably should be written into your admin's job description)

0 votes
John Funk
Community Champion
August 13, 2020

Hi @FlightSafetyS ,

I don't have an numbers to share, but I would say that it would be a huge impact. We did that about a year ago and it cut out all of the errors were were seeing do to the system getting bogged down. 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
AUG Leaders

Atlassian Community Events