Does validate method called before getValues method in JQL ?

Hi ,

I am upgrading jira from 5.0.7 to 5.2.11

Just wanted to know the flow of method calls in customJQL ?

In my case getValues method is getting called before validate method which is breaking the validation.

2 answers

0 vote

Typically it does, but not always (which is a bug imho).

If you are running a query in the issue nav, it will always be called first, however I have seen occassions where it doesn't, for instance when starting up jira and then going to the issue nav, the last query that user ran is run.

My workaround is to extract any query params etc in the getValues method as well, so factor out that code into some other routine rather than use class fields (which may cause you problems, as there is only ever a single JqlFunction instance).


for a workaround (not a solution) : I am calling the validate method from getValues method.

Still debugging and finding the correct solution.

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Julia Dillon
Posted Tuesday in Jira

Tell us how your team runs on Jira!

Hey Atlassian Community! Today we are launching a bunch of customer stories about the amazing work teams, like Dropbox and Twilio, are doing with Jira. You can check out the stories here. The thi...

648 views 1 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you