Package com.atlassian.sal.jira.executor
Class JiraThreadLocalContextManager
java.lang.Object
com.atlassian.sal.jira.executor.JiraThreadLocalContextManager
- All Implemented Interfaces:
com.atlassian.sal.api.executor.ThreadLocalContextManager<com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext>
public class JiraThreadLocalContextManager
extends Object
implements com.atlassian.sal.api.executor.ThreadLocalContextManager<com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext>
Manages the thread local state for JIRA
-
Constructor Summary
ConstructorsConstructorDescriptionJiraThreadLocalContextManager
(JiraAuthenticationContext authenticationContext, VelocityRequestContextFactory velocityRequestContextFactory, JiraTenantContext tenantContext, SpanningOperationHolder spanningOperationHolder, ScopesRequestCacheDelegate scopesRequestCacheDelegate) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Clear the thread local context on the current threadcom.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext
Get the thread local context of the current threadvoid
setThreadLocalContext
(com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext context) Set the thread local context on the current thread
-
Constructor Details
-
JiraThreadLocalContextManager
public JiraThreadLocalContextManager(JiraAuthenticationContext authenticationContext, VelocityRequestContextFactory velocityRequestContextFactory, JiraTenantContext tenantContext, SpanningOperationHolder spanningOperationHolder, ScopesRequestCacheDelegate scopesRequestCacheDelegate)
-
-
Method Details
-
getThreadLocalContext
public com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext getThreadLocalContext()Get the thread local context of the current thread- Specified by:
getThreadLocalContext
in interfacecom.atlassian.sal.api.executor.ThreadLocalContextManager<com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext>
- Returns:
- The thread local context
-
setThreadLocalContext
public void setThreadLocalContext(com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext context) Set the thread local context on the current thread- Specified by:
setThreadLocalContext
in interfacecom.atlassian.sal.api.executor.ThreadLocalContextManager<com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext>
- Parameters:
context
- The context to set
-
clearThreadLocalContext
public void clearThreadLocalContext()Clear the thread local context on the current thread- Specified by:
clearThreadLocalContext
in interfacecom.atlassian.sal.api.executor.ThreadLocalContextManager<com.atlassian.sal.jira.executor.JiraThreadLocalContextManager.JiraThreadLocalContext>
-