JIRA Rest API Service Development

gil March 27, 2018

I followed this tutorial for JIRA Rest API service development (https://developer.atlassian.com/server/framework/atlassian-sdk/developing-a-rest-service-plugin/), and have a question:

How do I destroy the session once the call is completed?  It looks like after a request is made to the Rest API service (from the same client computer), the session remain open for some time.   Even though the second call has a different username to the call, JIRA still captures the same, first username which made the first call.  I know this is the case because in my code, I use ApplicationUser user = ComponentAccessor.getJiraAuthenticationContext().getUser() -- it returns the same, first username even though in the 2nd call, it's a different user.

1 answer

0 votes
Alexey Matveev
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.
March 27, 2018

That is a very strange behaviour. Could you provide your source code? Or better take the source code from Bitbucket and try it:

https://bitbucket.org/serverecosystem/message/src/b4036f4a4fd68020a281ee6a3109cb398a8aa0da?at=master

Suggest an answer

Log in or Sign up to answer