79569162

Date: 2025-04-11 15:10:17
Score: 0.5
Natty:
Report link

there ist no solution from Atlassian, so here ist my Tip for Jira DataCenter

you can write a ScriptRunner Programm, wich uses the HttpSession and the Request Data

I have tested this in Chrome and Edge

(i wrote this in a helper Class so it is a static mehtod. After you have the "real" user (not the automation actor) you can do your work for example write a comment with the

ComponentAccessor.getCommentManager()

Here is the code

public static String getActualuser()
    {
        def request = ComponentAccessor.getComponent(HttpContext)?.getRequest()
        if (request) {
            HttpSession httpSession = request.getSession()
            def userid= httpSession.getAttribute('seraph_defaultauthenticator_user_id')
            return(userid )
        } else {
            return(null)
        }

    }

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: Juergen Mezger