Hi experts,
I am new to jira automation here. I am testing a automation to schedule send an email notification to reporter after 3 days the issue is due, But i am unable to figure out which IF condition to use or to use a JQL to test out the schedule trigger if it works. Appreciate your reply and thanks in advance.
I have checked the forum posts on a similiar issue using JQL: due < 3d and due > now() but having issues as well
Hi @jasonwongys and welcome to the Community!
First of all, you can add your JQL statement directly to a field in your scheduled trigger. You would not need to add an additional IF condition anymore.
Try a JQL like this:
due >= now() and due < 3d and statusCategory != Done and Assignee IS NOT empty
I would also strongly recommend a couple of additional tweaks:
Hope this helps!
Thanks Walter, the JQL works. While testing, i changed the JQL to assignee = "{myidname}" just to test the schedule function, i clicked run rules and when i checked my audit log it shows, NO ACTIONS PERFORMED. The assignee is myself
May i know the reason why even though the JQL matches the condition?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Rather than using automation you could just create a filter then add a subscription to that filter:
First ask your Site Admin to set up a Jira group e.g. 'Jira-developers' and assign everyone you want to receive the reminder to that group
Then create and save a filter using the following JQL:
assignee = currentuser() and duedate <= endOfDay(3d) and statusCategory != Done
Finally click on 'Filter subscriptions' next to the saved filter name and from the popup add a subscription with the recipients being 'Jira-developers', set up a daily schedule for email reminders (but make sure not to check the box for 'Email this filter, even if there are no issues found')
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am using automation because eventually i would want to transition the issue to a Closed status. I have explored subscription before but thanks for the suggestion Stephen!
My case study here is to tackle the issue where status under "User clarification" but users are not closing the issues on time, therefore instead of emailing them individually, i am automating this part as a reminder and if there are no action taken within 3 days. I will need to Closed the issues automatically.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can use the smart value {{issue.duedate.diff(now).days}} and it is > 3, then for such issues you can send out the email.
You will need to add a lookup action with JQL and then using below logic inside mail body, you can filter out the issues.
{{#lookupIssues}}
{{#if (due date.diff(now).days) > 3}}
...
{{/}}
{{/}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Will test this out. Thanks Vishal!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @jasonwongys
The JQL that @Walter Buggenhout suggested should do what you want, and although you could take his advice on including the JQL in the scheduled trigger I would suggest keeping it as a separate IF statement (at least while you are testing the automation.)
For testing the automation I would also suggest changing the trigger to a manual trigger that you can run from any existing issue rather than having to wait 5 minutes for the scheduled trigger to run.
When you have finished testing change the trigger back to a scheduled trigger running once a day before the working day starts, e.g. at 5am.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Point taken Stephen, as a newbie, i was trying out the schedule trigger and never managed to get it to work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
What may help is logging actions, for example when I want to test out IF statements without the next step I use a Log Actions action to log something like 'Condition passed' then you can test and modify the IF statement without doing something like sending an email or transitioning the status
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.