I have created 2 Escalation Services which have Action set to perform a transition. I'm now trying to create a 3rd Escalation Service which has Action set to none. When I run it, the comment is not being added, as it is with the other 2 Escalation Services.
It seems that not having an Action means no comment is added. Maybe because there is no screen?
Here's one of the Escalation services which have an action. The one I'm trying to add has a different JQL (still matches some issues), no Action, different comment, but still uses issueInputParameters.setComment.
Description: Transition inactive issues in Waiting For Reporter status to Inactive - Pending Closure status
Interval: 60
JQL: status = "Waiting For Reporter" AND updated <= -1w
Action: 301 Reporter Inactive
Run as: jirabot
Additional Code:def comment = """
This issue has not been updated for 7 days.
If you have an update, please update the issue. If you need more time to gather information please freeze the issue. If you have no other questions, please close this issue.
If no update is received in the next 7 days, this issue will be automatically closed.
Thank you,
Jira Automation Bot
WTS
"""
issueInputParameters.setComment(comment)
Which version of SR is this? Another customer has brought up this problem today, but I cannot reproduce it. I don't think you need to define an action to add a comment, as I have successfully added a comment without an action:
Thanks,
Josh
Our docs state:
Action
What action do you want to run on the issue? This is optional, you can use Additional Issue Actions instead or as well as
https://scriptrunner.adaptavist.com/latest/jira/escalation-service.html
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Jira 7.7.1 and Scriptrunner 5.3.5. I see 5.3.7 is available. I'll update now and try again.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Joshua Yamdogo @ Adaptavist I saw that as well.
I just tried again with 5.3.7. In the add escalation service screen, I click Run now, and it shows 63 issues returned and says they were updated (as yours did), but none of the issues have any comment added. I can also click Run now again, and it still says 63 issues returned -- but there should be 0 if a comment was just added, since the JQL query is looking for issues update <= -2w.
Here's a screenshot:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the info, Andrew. Have you tried the built-in script to reindex all issues?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Is this different than doing a reindex under System > Indexing? I'll be doing a system reindex in about 10 minutes, after our helpdesk closes for the day.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That's fine. The built-in ScriptRunner reindex script just quickly reindexes all the issues, which the standard JIRA reindex already covers.
Did the reindex make any difference?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We have a fairly large instance. It's been going for about 45 minutes and is about 35% done. I'll let it finish over night and update tomorrow.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The reindex is complete. I've just run the escalation service again, twice, and no comments are added.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Andrew,
Thanks for getting back to me. We would like to take a closer look at this - can you make a ticket through our support portal with the information from this Community question?
https://marketplace.atlassian.com/plugins/com.onresolve.jira.groovy.groovyrunner/server/support
Regards,
Josh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.