Multiple emails being sent to the same user

We have Script Runner 4.1.3.8, using it to send a custom email to users but the users are receiving 3 or 4 of the same email for the same ticket.

Nothing in the Notification Schemes is triggering secondary emails.

I need this to stop as it is causing some confusion for the users.

Is this an issue with ScriptRunner?

6 answers

0 votes
Joe Pitt Community Champion Aug 30, 2016

It sounds like whatever is in script runner is in addition to what the notification scheme would do. Did anyone modify either the notification scheme or script runner. If you don't know I'd start by turning script runner off.

There is way too much functionality with Script Runner to turn it off and there isn't a separate Test environment.

The Notification scheme has no recipients for the event that triggers the custom email.

Any other suggestions? Unless you know how to turn off just parts of script runner. 

I assume you're using the Send custom email post function in one of your workflows. 

Several questions to help debug this:

  1. Are the emails the users are receiving identical? Or are there differences between them.
  2. Do multiple workflow transitions have this step? If so, it may be that users are getting the emails because the issue is going through multiple workflows.
  3. Could anything be triggering the workflow multiple times?

I am.

The emails are identical. The logs in the script listener only show the listener being triggered once. The outgoing mail log shows the email being sent multiple times but I haven't found why so many are being sent.

The emails are listening for a custom event that is only used once in one workflow.

The custom event is only in that one transition and the listener isn't listening for any other events.

Think you could share your listener's configuration and the configuration of your workflow? If the listener is only firing once, it could be that the same email address is getting included multiple times via the To Addresses, To Issue Fields, CC fields, etc.

the email only goes to assignees and watchers - but there are no watchers and the assignee is not autowatching the issue.

I can add the configuration later today if you think the rest of it will help

It could prove helpful, yeah.

Another thing to test is whether other methods of sending emails outside of ScriptRunner send multiple messages as well. If so, then it may be an issue with your Mail Server settings in JIRA itself, not the post function.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Friday in Jira Service Desk

Looking for anyone who has switched from Zendesk to Jira Service Desk

Hi Community! The Jira Service Desk marketing team is looking for customers who have successfully switched from Zendesk to Jira Service Desk!   We’d love to hear your thoughts on the pros and ...

36 views 0 1
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