org.camunda.bpm.engine.impl.interceptor
Class CommandContext

java.lang.Object
  extended by org.camunda.bpm.engine.impl.interceptor.CommandContext

public class CommandContext
extends Object

Author:
Tom Baeyens, Agim Emruli, Daniel Meyer

Field Summary
protected  boolean authorizationCheckEnabled
           
protected  List<CommandContextListener> commandContextListeners
           
protected  JobEntity currentJob
           
protected  FailedJobCommandFactory failedJobCommandFactory
           
protected  String operationId
           
protected  ProcessEngineConfigurationImpl processEngineConfiguration
           
protected  boolean restrictUserOperationLogToAuthenticatedUsers
           
protected  Map<Class<?>,SessionFactory> sessionFactories
           
protected  List<Session> sessionList
           
protected  Map<Class<?>,Session> sessions
           
protected  boolean tenantCheckEnabled
           
protected  TransactionContext transactionContext
           
protected  boolean userOperationLogEnabled
           
 
Constructor Summary
CommandContext(ProcessEngineConfigurationImpl processEngineConfiguration)
           
CommandContext(ProcessEngineConfigurationImpl processEngineConfiguration, TransactionContextFactory transactionContextFactory)
           
 
Method Summary
 void close(CommandInvocationContext commandInvocationContext)
           
protected  void closeSessions(CommandInvocationContext commandInvocationContext)
           
 void disableAuthorizationCheck()
           
 void disableTenantCheck()
           
 void disableUserOperationLog()
           
 void enableAuthorizationCheck()
           
 void enableTenantCheck()
           
 void enableUserOperationLog()
           
protected  void fireCommandContextClose()
           
protected  void fireCommandFailed(Throwable t)
           
protected  void flushSessions()
           
 AttachmentManager getAttachmentManager()
           
 List<String> getAuthenticatedGroupIds()
           
 String getAuthenticatedUserId()
           
 Authentication getAuthentication()
           
 AuthorizationManager getAuthorizationManager()
           
 BatchManager getBatchManager()
           
 ByteArrayManager getByteArrayManager()
           
 CaseDefinitionManager getCaseDefinitionManager()
           
 CaseExecutionManager getCaseExecutionManager()
           
 CaseSentryPartManager getCaseSentryPartManager()
           
 CommentManager getCommentManager()
           
 JobEntity getCurrentJob()
           
 DbEntityManager getDbEntityManager()
           
 DbSqlSession getDbSqlSession()
           
 DecisionDefinitionManager getDecisionDefinitionManager()
           
 DecisionRequirementsDefinitionManager getDecisionRequirementsDefinitionManager()
           
 DeploymentManager getDeploymentManager()
           
 EventSubscriptionManager getEventSubscriptionManager()
           
 ExecutionManager getExecutionManager()
           
 ExternalTaskManager getExternalTaskManager()
           
 FailedJobCommandFactory getFailedJobCommandFactory()
           
 FilterManager getFilterManager()
           
 HistoricActivityInstanceManager getHistoricActivityInstanceManager()
           
 HistoricBatchManager getHistoricBatchManager()
           
 HistoricCaseActivityInstanceManager getHistoricCaseActivityInstanceManager()
           
 HistoricCaseInstanceManager getHistoricCaseInstanceManager()
           
 HistoricDecisionInstanceManager getHistoricDecisionInstanceManager()
           
 HistoricDetailManager getHistoricDetailManager()
           
 HistoricExternalTaskLogManager getHistoricExternalTaskLogManager()
           
 HistoricIdentityLinkLogManager getHistoricIdentityLinkManager()
           
 HistoricIncidentManager getHistoricIncidentManager()
           
 HistoricJobLogManager getHistoricJobLogManager()
           
 HistoricProcessInstanceManager getHistoricProcessInstanceManager()
           
 ReportManager getHistoricReportManager()
           
 HistoricStatisticsManager getHistoricStatisticsManager()
           
 HistoricTaskInstanceManager getHistoricTaskInstanceManager()
           
 HistoricVariableInstanceManager getHistoricVariableInstanceManager()
           
 IdentityInfoManager getIdentityInfoManager()
           
 IdentityLinkManager getIdentityLinkManager()
           
 IncidentManager getIncidentManager()
           
 JobDefinitionManager getJobDefinitionManager()
           
 JobManager getJobManager()
           
 MeterLogManager getMeterLogManager()
           
 String getOperationId()
           
 UserOperationLogManager getOperationLogManager()
           
 ProcessDefinitionManager getProcessDefinitionManager()
           
 ProcessEngineConfigurationImpl getProcessEngineConfiguration()
           
 PropertyManager getPropertyManager()
           
 ReadOnlyIdentityProvider getReadOnlyIdentityProvider()
           
 ResourceManager getResourceManager()
           
<T> T
getSession(Class<T> sessionClass)
           
 Map<Class<?>,SessionFactory> getSessionFactories()
           
 Map<Class<?>,Session> getSessions()
           
 StatisticsManager getStatisticsManager()
           
 TableDataManager getTableDataManager()
           
protected  ProcessApplicationReference getTargetProcessApplication(CaseExecutionEntity execution)
           
 TaskManager getTaskManager()
           
 TaskReportManager getTaskReportManager()
           
 TenantManager getTenantManager()
           
 TransactionContext getTransactionContext()
           
 VariableInstanceManager getVariableInstanceManager()
           
 WritableIdentityProvider getWritableIdentityProvider()
           
 boolean isAuthorizationCheckEnabled()
           
 boolean isRestrictUserOperationLogToAuthenticatedUsers()
           
 boolean isTenantCheckEnabled()
           
 boolean isUserOperationLogEnabled()
           
 void performOperation(CmmnAtomicOperation executionOperation, CaseExecutionEntity execution)
           
 void registerCommandContextListener(CommandContextListener commandContextListener)
           
protected  boolean requiresContextSwitch(ProcessApplicationReference processApplicationReference)
           
<T> T
runWithoutAuthorization(Callable<T> runnable)
           
 void setAuthorizationCheckEnabled(boolean authorizationCheckEnabled)
           
 void setCurrentJob(JobEntity currentJob)
           
 void setLogUserOperationEnabled(boolean userOperationLogEnabled)
           
 void setOperationId(String operationId)
           
 void setRestrictUserOperationLogToAuthenticatedUsers(boolean restrictUserOperationLogToAuthenticatedUsers)
           
 void setTenantCheckEnabled(boolean tenantCheckEnabled)
           
protected  boolean shouldLogFine(Throwable exception)
           
protected  boolean shouldLogInfo(Throwable exception)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

authorizationCheckEnabled

protected boolean authorizationCheckEnabled

userOperationLogEnabled

protected boolean userOperationLogEnabled

tenantCheckEnabled

protected boolean tenantCheckEnabled

restrictUserOperationLogToAuthenticatedUsers

protected boolean restrictUserOperationLogToAuthenticatedUsers

transactionContext

protected TransactionContext transactionContext

sessionFactories

protected Map<Class<?>,SessionFactory> sessionFactories

sessions

protected Map<Class<?>,Session> sessions

sessionList

protected List<Session> sessionList

processEngineConfiguration

protected ProcessEngineConfigurationImpl processEngineConfiguration

failedJobCommandFactory

protected FailedJobCommandFactory failedJobCommandFactory

currentJob

protected JobEntity currentJob

commandContextListeners

protected List<CommandContextListener> commandContextListeners

operationId

protected String operationId
Constructor Detail

CommandContext

public CommandContext(ProcessEngineConfigurationImpl processEngineConfiguration)

CommandContext

public CommandContext(ProcessEngineConfigurationImpl processEngineConfiguration,
                      TransactionContextFactory transactionContextFactory)
Method Detail

performOperation

public void performOperation(CmmnAtomicOperation executionOperation,
                             CaseExecutionEntity execution)

getProcessEngineConfiguration

public ProcessEngineConfigurationImpl getProcessEngineConfiguration()

getTargetProcessApplication

protected ProcessApplicationReference getTargetProcessApplication(CaseExecutionEntity execution)

requiresContextSwitch

protected boolean requiresContextSwitch(ProcessApplicationReference processApplicationReference)

close

public void close(CommandInvocationContext commandInvocationContext)

shouldLogInfo

protected boolean shouldLogInfo(Throwable exception)

shouldLogFine

protected boolean shouldLogFine(Throwable exception)

fireCommandContextClose

protected void fireCommandContextClose()

fireCommandFailed

protected void fireCommandFailed(Throwable t)

flushSessions

protected void flushSessions()

closeSessions

protected void closeSessions(CommandInvocationContext commandInvocationContext)

getSession

public <T> T getSession(Class<T> sessionClass)

getDbEntityManager

public DbEntityManager getDbEntityManager()

getDbSqlSession

public DbSqlSession getDbSqlSession()

getDeploymentManager

public DeploymentManager getDeploymentManager()

getResourceManager

public ResourceManager getResourceManager()

getByteArrayManager

public ByteArrayManager getByteArrayManager()

getProcessDefinitionManager

public ProcessDefinitionManager getProcessDefinitionManager()

getExecutionManager

public ExecutionManager getExecutionManager()

getTaskManager

public TaskManager getTaskManager()

getTaskReportManager

public TaskReportManager getTaskReportManager()

getMeterLogManager

public MeterLogManager getMeterLogManager()

getIdentityLinkManager

public IdentityLinkManager getIdentityLinkManager()

getVariableInstanceManager

public VariableInstanceManager getVariableInstanceManager()

getHistoricProcessInstanceManager

public HistoricProcessInstanceManager getHistoricProcessInstanceManager()

getHistoricCaseInstanceManager

public HistoricCaseInstanceManager getHistoricCaseInstanceManager()

getHistoricDetailManager

public HistoricDetailManager getHistoricDetailManager()

getOperationLogManager

public UserOperationLogManager getOperationLogManager()

getHistoricVariableInstanceManager

public HistoricVariableInstanceManager getHistoricVariableInstanceManager()

getHistoricActivityInstanceManager

public HistoricActivityInstanceManager getHistoricActivityInstanceManager()

getHistoricCaseActivityInstanceManager

public HistoricCaseActivityInstanceManager getHistoricCaseActivityInstanceManager()

getHistoricTaskInstanceManager

public HistoricTaskInstanceManager getHistoricTaskInstanceManager()

getHistoricIncidentManager

public HistoricIncidentManager getHistoricIncidentManager()

getHistoricIdentityLinkManager

public HistoricIdentityLinkLogManager getHistoricIdentityLinkManager()

getJobManager

public JobManager getJobManager()

getBatchManager

public BatchManager getBatchManager()

getHistoricBatchManager

public HistoricBatchManager getHistoricBatchManager()

getJobDefinitionManager

public JobDefinitionManager getJobDefinitionManager()

getIncidentManager

public IncidentManager getIncidentManager()

getIdentityInfoManager

public IdentityInfoManager getIdentityInfoManager()

getAttachmentManager

public AttachmentManager getAttachmentManager()

getTableDataManager

public TableDataManager getTableDataManager()

getCommentManager

public CommentManager getCommentManager()

getEventSubscriptionManager

public EventSubscriptionManager getEventSubscriptionManager()

getSessionFactories

public Map<Class<?>,SessionFactory> getSessionFactories()

getPropertyManager

public PropertyManager getPropertyManager()

getStatisticsManager

public StatisticsManager getStatisticsManager()

getHistoricStatisticsManager

public HistoricStatisticsManager getHistoricStatisticsManager()

getHistoricJobLogManager

public HistoricJobLogManager getHistoricJobLogManager()

getHistoricExternalTaskLogManager

public HistoricExternalTaskLogManager getHistoricExternalTaskLogManager()

getHistoricReportManager

public ReportManager getHistoricReportManager()

getAuthorizationManager

public AuthorizationManager getAuthorizationManager()

getReadOnlyIdentityProvider

public ReadOnlyIdentityProvider getReadOnlyIdentityProvider()

getWritableIdentityProvider

public WritableIdentityProvider getWritableIdentityProvider()

getTenantManager

public TenantManager getTenantManager()

getCaseDefinitionManager

public CaseDefinitionManager getCaseDefinitionManager()

getCaseExecutionManager

public CaseExecutionManager getCaseExecutionManager()

getCaseSentryPartManager

public CaseSentryPartManager getCaseSentryPartManager()

getDecisionDefinitionManager

public DecisionDefinitionManager getDecisionDefinitionManager()

getDecisionRequirementsDefinitionManager

public DecisionRequirementsDefinitionManager getDecisionRequirementsDefinitionManager()

getHistoricDecisionInstanceManager

public HistoricDecisionInstanceManager getHistoricDecisionInstanceManager()

getFilterManager

public FilterManager getFilterManager()

getExternalTaskManager

public ExternalTaskManager getExternalTaskManager()

registerCommandContextListener

public void registerCommandContextListener(CommandContextListener commandContextListener)

getTransactionContext

public TransactionContext getTransactionContext()

getSessions

public Map<Class<?>,Session> getSessions()

getFailedJobCommandFactory

public FailedJobCommandFactory getFailedJobCommandFactory()

getAuthentication

public Authentication getAuthentication()

runWithoutAuthorization

public <T> T runWithoutAuthorization(Callable<T> runnable)

getAuthenticatedUserId

public String getAuthenticatedUserId()

getAuthenticatedGroupIds

public List<String> getAuthenticatedGroupIds()

enableAuthorizationCheck

public void enableAuthorizationCheck()

disableAuthorizationCheck

public void disableAuthorizationCheck()

isAuthorizationCheckEnabled

public boolean isAuthorizationCheckEnabled()

setAuthorizationCheckEnabled

public void setAuthorizationCheckEnabled(boolean authorizationCheckEnabled)

enableUserOperationLog

public void enableUserOperationLog()

disableUserOperationLog

public void disableUserOperationLog()

isUserOperationLogEnabled

public boolean isUserOperationLogEnabled()

setLogUserOperationEnabled

public void setLogUserOperationEnabled(boolean userOperationLogEnabled)

enableTenantCheck

public void enableTenantCheck()

disableTenantCheck

public void disableTenantCheck()

setTenantCheckEnabled

public void setTenantCheckEnabled(boolean tenantCheckEnabled)

isTenantCheckEnabled

public boolean isTenantCheckEnabled()

getCurrentJob

public JobEntity getCurrentJob()

setCurrentJob

public void setCurrentJob(JobEntity currentJob)

isRestrictUserOperationLogToAuthenticatedUsers

public boolean isRestrictUserOperationLogToAuthenticatedUsers()

setRestrictUserOperationLogToAuthenticatedUsers

public void setRestrictUserOperationLogToAuthenticatedUsers(boolean restrictUserOperationLogToAuthenticatedUsers)

getOperationId

public String getOperationId()

setOperationId

public void setOperationId(String operationId)


Copyright © 2017 camunda services GmbH. All rights reserved.