Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Email notification after x days an issue is in a given state (or do not get updated)

Info-One December 12, 2013

Hello.

We created a "blocked" state in our workflows. An issue in this state is waiting for an event to happen; we would like to get notified when that event does not happen for a fixed amount of time, e.g. 3 days.

If that is not possible easily, we could live with an email notification for all issues in a given state and that did not get modified in the last 3 days. I could easily create a filter for this last point, but I do not figure out a way to associate filter results to email notifications.

Is there a solution for either one of the two issues?

2 answers

1 vote
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 12, 2013

Both can be done with simple Jelly escalation scripts - see https://confluence.atlassian.com/display/JIRA/Jelly+Escalation

0 votes
Info-One December 12, 2013

Thank you, this is my solution (which I still need to test) that adds a comment to an issue blocked for 5 days.

blockedFor5Days is: "status=Blocked AND updatedDate = -5d"

<JiraJelly xmlns:jira= "jelly:com.atlassian.jira.jelly.enterprise.JiraTagLib" xmlns:core= "jelly:core" xmlns:log="jelly:log" >

<jira:Login username="..." password="...">

 <log:warn>Check on blocked issues</log:warn>
 
 <core:set var="blockedFor5Days" value="10000" />

 <jira:RunSearchRequest filterid="${blockedFor5Days}" var="issues" />

 
 <core:set var="blocked" value="blocked" />

 <core:forEach var="issue" items="${issues}">

<core:set var="status" value="${issues.status}" />
		
	<core:iftest="${blocked==status}">

	<core:set var="comment">Issue blocked too long</core:set>

		 <jira:AddComment issue-key="${issue.key}" comment="${comment}"/>		

	</core:if>
		
 </core:forEach>

</jira:Login>

</JiraJelly>

I would expect this guy to send an email on the fifth day the issue is blocked. What do you think? I am currently running an on demand version, so I cannot test them right away. I will test as soon as we move to the downloadable version.

Suggest an answer

Log in or Sign up to answer