Forums

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

How to notify users when an issue is read ?

Damien Picard May 31, 2018

Hi,

Some of my users ask me to add a hook to notify them when an issue is read by somebody.

To do that, I'm building a plugin using this tuto :

https://developer.atlassian.com/server/framework/atlassian-sdk/adding-activities-to-a-third-party-feed-with-the-java-api/

Everything is ok with the plugins, but I see that there is no "read" event :

https://docs.atlassian.com/software/jira/docs/api/5.1.4/com/atlassian/jira/event/type/EventType.html

(Yes, I work on JIRA 5.1.4, and no, it is not planed to upgrade, I'm sorry)

So my question is, how can I be notified when someone read some issue ?

 

Thank you in advance.

Damien.

1 answer

1 accepted

1 vote
Answer accepted
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.
May 31, 2018

An upgrade won't help you, there's no "read" in later versions either.  It's too potentially loading to implement.  It might be ok if it were just the issue view, but there are many ways to "read" an issue, and an event would probably have to cover most of them.  Do you consider a view of it in the issue navigator as read?  On a board?  In a backlog? 

If you do inject something to do this, it is going to have to think about who reads it, and supressing any further "read" flags.  It's going to be a lot of work and a lot of storage for little reward.

Personally, I don't believe this is of much use in a real process.  I don't actually care if someone reads the issues, I care if they act on them.  If they're not reading them because they don't know about them, that's a human or process problem, not something I can solve with a read receipt.  If I need someone to pay attention, make them a watcher, or better @mention them directly.  Or even assign it to them.

Damien Picard May 31, 2018

Thank you Nic,

You are right, there is a lot of way to read a ticket, and I think we will not handle all of them (most probably the /browse/TICKET-1 url only).

We would enable this function only for a little project, (max 20 persons). And the tickets will not be readable by a lot of them (3 or 4 persons per ticket). So it would not generate so much data. 

I let the business team decides if the reward matches the cost ; I estimate the work to do, they decide and they pay.

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.
May 31, 2018

I suspect the best approach would be a little bit of javascript injection into the issue view which could call a (local) REST endpoint that could then check for previous views, trigger an email if there are none,  and then record the view.

I don't think that would be a huge chunk of work - an App could bundle up a javascript tweak and the data-store stuff quite quickly (a slightly dirty cheat would be to add a custom field for "issue was read" and using it to avoid having to think about other ways to save it)

Damien Picard June 1, 2018

Thank you,

I think that the javascript approach is a good suggestion ; I will give it a try. I think that it has to be done this way :

https://developer.atlassian.com/server/jira/platform/web-resource/

In a first time, I will juste post a comment in the issue telling that "User X has read this issue" ; this way, every read will be time-stamped and historized (and if needed, an email can be sent).

Inbar Levi January 12, 2023

Hi @Damien Picard , did you manage to do so? can you share the script, please? 

Suggest an answer

Log in or Sign up to answer