Groovy script doesn't work on JIRA 6.0.8

Hi all!

Simple groovy script on "Create Issue" with one line code doesn't work.

issue.description += "Test from Groovy"


issue.summary += "Test from Groovy"

Log file is empty.

Any ideas why?



2 answers

1 accepted

1 vote
Accepted answer

If the changes should be done after the issue is created you have to add a

after changing the summary. Additionally you have to update the index via the IssueIndexManager.reIndex() method.

Maybe you could try without a reindex if you place the post function before the reindex and you are sure you're using the original issue object (like you do in your simple script in you question).

Henning Tietgens, thanks!

Try move the postfunction to the first position of post functions.

Because "Create the issue originally" creates and saves the issue to the database and the changes to the issue object should take place before this function.

Henning Tietgens, it's necessary to update description after issue creation. Is there any way to update issue's description after originally issue is created?

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Jan 08, 2019 in Jira

How to Jira for designers

I’m a designer on the Jira team. For a long time, I’ve fielded questions from other designers about how they should be using Jira Software with their design team. I’ve also heard feedback from other ...

1,124 views 4 9
Read article

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