Can Scriptrunner be able to update comments on linked issues?

JIRA: 7.1.8

Scriptrunner: 4.3.5

Service desk: 3.1.10

I am evaluating Service desk and I am using some of the workflow functionality of Scriptrunner to do some automation. The goal on this is to have a minimal effort in maintaining service desk issues and be able to communicate directly to the software/developer group and the user will stay in the service desk portal.

 

Use Case:

  • A user creates a request from service desk portal
    • Scriptrunner post function will clone and link an issue to a JIRA software project (no problem here)
    • Service desk project automation handles the changes on the linked issue status to update the issue status (no problem here)
  • Issue
    • Non-agent can't comment directly on the service desk issue, is there a way to comment in the JIRA software issue and automatically uploads that comment to the service desk issue?
      • This will allow the communication without a help desk personnel 

Thanks,

Rex 

3 answers

Yes. This is possible. But, nontrivial.

There is an issueCommented event that can invoke a script listener. Since the script has full access to the JIRA API, you can navigate to the issue the comment is attached to, from there to the links and to the service desk issue where you want to replicate the comment.

Alternatively, you could give your non-agents the Service Desk collaborator role which only allows them to view service desk issues, and add comments and attachments. 

Thanks Doug,

The non-agents as a Service Desk collaborator can only comment internally not directly to the Service desk customer.

I tried these ones and its not exactly what I was looking for:

https://answers.atlassian.com/questions/12278154

Script listener for Generic Event that fires off a "Comment" event if a comment was created

 

 

 

Given that you've tried some code, but it's not working, what is the behavior that's not working for you?

  • You successfully create the comment on the service desk issue but the comment is only internal and the customer can't see it?
  • The groovy code fails with an exception?
  • The groovy code never gets executed?
  • Something else?

 

 

To answer your question Doug:

  • I did a comment on the JIRA issue but it doesn't update/copy to the linked service desk issue
  • It seems like the groovy code was executing to what it's supposed to do, but as I said it's not doing what I was hoping to happen

Thanks for the time Doug 

 

To Jamie's comment:

  • In our company the help desk group are using Service Now and in our group we are using Atlassian products
  • It is a bad workflow for developers talking directly to users, I would prefer agents to be talking to users, but with our current structure, I don't have a dedicated service desk agent
  • I will try one more time to do the event listener on "issue commented" process, if it doesn't work then I will find another workaround or leave it as is

Thanks for the time Jamie 

0 votes

You can have an event listener on "issue commented" in the software project, then use com.atlassian.jira.issue.comments.CommentManager#create to create the same comment on the software project.

You would have to create it as a service desk agent that has permissions on that project.

I would say this is not hard, but to me this sounds like a bad workflow. Let the agents speak to the users, and the developers speak to the agents, or get all the info they need from their dev ticket...?

It turns out that developers don't often use the correct language when speaking to end users, particularly if it's not even clear that their comment will be seen by the end user.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 18, 2018 in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

20,744 views 2 7
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