Package pro.taskana.common.internal
Interface InternalTaskanaEngine
public interface InternalTaskanaEngine
FOR INTERNAL USE ONLY.
Contains all actions which are necessary within taskana.
-
Method Summary
Modifier and TypeMethodDescriptionbooleandomainExists(String domain) Returns true if the given domain does exist in the configuration.default voidexecuteInDatabaseConnection(Runnable runnable) Executes the given runnable after openConnection is called and then returns the connection.<T> TexecuteInDatabaseConnection(Supplier<T> supplier) Executes the given supplier after openConnection is called and then returns the connection.Retrieves the AfterRequestChangesManager.Retrieves the AfterRequestReviewManager.Retrieves the BeforeRequestChangesManager.Retrieves the BeforeRequestReviewManager.Retrieve CreateTaskPreprocessorManager.Retrieve TaskanaEngine.Retrieve HistoryEventProducer.Retrieves the PriorityServiceManager.Retrieves the ReviewRequiredManager.org.apache.ibatis.session.SqlSessionretrieve the SqlSession used by taskana.Retrieves the TaskEndstatePreprocessorManager.Retrieve TaskRoutingProducer.voidInitializes the SqlSessionManager.voidOpens the connection to the database.voidReturns the database connection into the pool.
-
Method Details
-
openConnection
void openConnection()Opens the connection to the database. Has to be called at the beginning of each Api call that accesses the database -
returnConnection
void returnConnection()Returns the database connection into the pool. In the case of nested calls, simply pops the latest session from the session stack. Closes the connection if the session stack is empty. In mode AUTOCOMMIT commits before the connection is closed. To be called at the end of each Api call that accesses the database -
executeInDatabaseConnection
Executes the given supplier after openConnection is called and then returns the connection.- Type Parameters:
T- any type- Parameters:
supplier- a function that returns something of type T- Returns:
- the result of the supplier
-
executeInDatabaseConnection
Executes the given runnable after openConnection is called and then returns the connection.- See Also:
-
initSqlSession
void initSqlSession()Initializes the SqlSessionManager. -
domainExists
Returns true if the given domain does exist in the configuration.- Parameters:
domain- the domain specified in the configuration- Returns:
trueif the domain exists
-
getSqlSession
org.apache.ibatis.session.SqlSession getSqlSession()retrieve the SqlSession used by taskana.- Returns:
- the myBatis SqlSession object used by taskana
-
getEngine
TaskanaEngine getEngine()Retrieve TaskanaEngine.- Returns:
- The nested TaskanaEngine.
-
getHistoryEventManager
HistoryEventManager getHistoryEventManager()Retrieve HistoryEventProducer.- Returns:
- the HistoryEventProducer instance.
-
getTaskRoutingManager
TaskRoutingManager getTaskRoutingManager()Retrieve TaskRoutingProducer.- Returns:
- the TaskRoutingProducer instance.
-
getCreateTaskPreprocessorManager
CreateTaskPreprocessorManager getCreateTaskPreprocessorManager()Retrieve CreateTaskPreprocessorManager.- Returns:
- the CreateTaskPreprocessorManager instance.
-
getPriorityServiceManager
PriorityServiceManager getPriorityServiceManager()Retrieves the PriorityServiceManager.- Returns:
- the PriorityServiceManager instance
-
getReviewRequiredManager
ReviewRequiredManager getReviewRequiredManager()Retrieves the ReviewRequiredManager.- Returns:
- the ReviewRequiredManager instance
-
getBeforeRequestReviewManager
BeforeRequestReviewManager getBeforeRequestReviewManager()Retrieves the BeforeRequestReviewManager.- Returns:
- the BeforeRequestReviewManager instance
-
getAfterRequestReviewManager
AfterRequestReviewManager getAfterRequestReviewManager()Retrieves the AfterRequestReviewManager.- Returns:
- the AfterRequestReviewManager instance
-
getBeforeRequestChangesManager
BeforeRequestChangesManager getBeforeRequestChangesManager()Retrieves the BeforeRequestChangesManager.- Returns:
- the BeforeRequestChangesManager instance
-
getAfterRequestChangesManager
AfterRequestChangesManager getAfterRequestChangesManager()Retrieves the AfterRequestChangesManager.- Returns:
- the AfterRequestChangesManager instance
-
getTaskEndstatePreprocessorManager
TaskEndstatePreprocessorManager getTaskEndstatePreprocessorManager()Retrieves the TaskEndstatePreprocessorManager.- Returns:
- the TaskEndstatePreprocessorManager instance
-