When performing a workflow transition in JIRA, optionally a comment can be added. In one of our projects, we have a multi user picker custom field called Management Notifications. Whenever a comment is added to an issue, users who are in this custom field must be emailed, but none of the other events.
What we have done is associating the 'Management Notifications' field to the 'Issue Commented' event in the notification scheme.
This setup does not work when a comment is added along with a status transition. Is there a workaround to fix this?
the notification is not being send because while executing the status transition an associated event is fired, which is generally not the "issue commented" event. Please check the event fired in your transition (you can see it in the postfunctions of the transition) and associate the event with the multiuser picker custom field (assuming that you wish to notify users) in your notification scheme. Or, you can edit your workflow and set the issue commented event to be fired while executing the transition.
Hope this helps,
Thank you for the answer.
In our requierment, once a transition is happended, there's a set of people to be notified.
Once a comment is added, there's another set of people to be notified. Thse people do not want to get too many e-mails flooded in their mailboxes, therefore only the commented event, nothing more.
Looks like the Issue Commented event is supressed by the Generic, Create, Close, etc. events. What I'm looking for the 'union' of these two event notifications, while managing to send only one e-mail per person.
In your suggestion, if we edit the workflow and set the Issue Commented event as the post function, Management Notifications will also be notified with status changes. In the other hand, it's the same as adding the custom field to Generic, Create, Close events without editing the workflow.
This is one of those all or nothing settings that's a bit inflexible. For example, you want watchers to always be notified when a comment occurs in a transition, but not when the transition is missing a comment. What users probably end-up doing is erring on side of not-missing comments, and email regardless.
In the past, one could get by simply wrapping the event called. For example, fire an event "Transition Comment" via a ScriptListener (Scriptrunner). In your script check if comment is null, or not. If it is, fire a "Comment" event. Otherwise, fire an "Update" event.
This works fine but if you enable Batching in version 8+, this can cause some problems and may result in a duplicate comment appearing in the emails if you mention a person, and they are already a watcher (but due to a bug, this seems unavoidable anyway). Anyway, if they do fix the bug, I suspect you'll need to patch "FireIssueEventFunction.java" to intercept and fire the correct event, or turn off Batching.
Hi Atlassian Community! We recently partnered together with Slack on a webinar, “ Transform cross-functional collaboration with Slack + Atlassian ”. Building fast, growing exponentially: all...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events