Class DataObjectEngineConfiguration

  • All Implemented Interfaces:
    DataObjectEngineConfigurationApi, org.flowable.common.engine.impl.HasVariableTypes, org.flowable.common.spring.SpringEngineConfiguration, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.Lifecycle, org.springframework.context.Phased, org.springframework.context.SmartLifecycle

    public class DataObjectEngineConfiguration
    extends org.flowable.common.engine.impl.AbstractEngineConfiguration
    implements org.flowable.common.spring.SpringEngineConfiguration, DataObjectEngineConfigurationApi, org.flowable.common.engine.impl.HasVariableTypes
    Author:
    Filip Hrisafov
    • Field Detail

      • DEFAULT_MYBATIS_MAPPING_FILE

        public static final java.lang.String DEFAULT_MYBATIS_MAPPING_FILE
        See Also:
        Constant Field Values
      • DEFAULT_ENGINE_NAME

        public static final java.lang.String DEFAULT_ENGINE_NAME
        See Also:
        Constant Field Values
      • KEY_DATA_OBJECT_ENGINE_CONFIG

        public static final java.lang.String KEY_DATA_OBJECT_ENGINE_CONFIG
        See Also:
        Constant Field Values
      • LIQUIBASE_CHANGELOG_PREFIX

        public static final java.lang.String LIQUIBASE_CHANGELOG_PREFIX
        See Also:
        Constant Field Values
      • dataObjectEngineName

        protected java.lang.String dataObjectEngineName
      • dataObjectDataSources

        protected java.util.Map<java.lang.String,​DataObjectDataSource> dataObjectDataSources
      • serviceRegistryDataObjectOperations

        protected DataObjectOperations serviceRegistryDataObjectOperations
      • transactionManager

        protected org.springframework.transaction.PlatformTransactionManager transactionManager
      • transactionSynchronizationAdapterOrder

        protected java.lang.Integer transactionSynchronizationAdapterOrder
      • namedParameterJdbcOperations

        protected org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations namedParameterJdbcOperations
      • applicationContext

        protected org.springframework.context.ApplicationContext applicationContext
      • running

        protected volatile boolean running
      • dataObjectSchemaDefinitionDeployer

        protected org.flowable.common.engine.impl.EngineDeployer dataObjectSchemaDefinitionDeployer
      • dataObjectDefinitionCacheLimit

        protected int dataObjectDefinitionCacheLimit
      • dataObjectDefinitionCache

        protected org.flowable.common.engine.impl.persistence.deploy.DeploymentCache<DataObjectDefinitionCacheEntry> dataObjectDefinitionCache
      • variableTypes

        protected org.flowable.variable.api.types.VariableTypes variableTypes
      • customPreVariableTypes

        protected java.util.List<org.flowable.variable.api.types.VariableType> customPreVariableTypes
      • customPostVariableTypes

        protected java.util.List<org.flowable.variable.api.types.VariableType> customPostVariableTypes
      • serializableVariableTypeTrackDeserializedObjects

        protected boolean serializableVariableTypeTrackDeserializedObjects
      • deploymentName

        protected java.lang.String deploymentName
      • deploymentResources

        protected org.springframework.core.io.Resource[] deploymentResources
      • deploymentMode

        protected java.lang.String deploymentMode
      • enginesBuild

        protected java.util.List<java.lang.String> enginesBuild
      • lifeCycleMonitor

        protected final java.lang.Object lifeCycleMonitor
      • autoUpdateDataObjectSchemaDefinitions

        protected boolean autoUpdateDataObjectSchemaDefinitions
        If set to true the liquibase changelog from the DataObjectSchemaDefinition(s) will be automatically updated during engine boot time. This property is usually OK to be set only during development time.
      • jsonVariableTypeTrackObjects

        protected boolean jsonVariableTypeTrackObjects
        This flag determines whether variables of the type 'json' and 'longJson' will be tracked.

        This means that, when true, in a JavaDelegate you can write:

        
             JsonNode jsonNode = (JsonNode) execution.getVariable("customer");
             customer.put("name", "Kermit");
         
        And the changes to the JsonNode will be reflected in the database. Otherwise, a manual call to setVariable will be needed.
    • Constructor Detail

      • DataObjectEngineConfiguration

        public DataObjectEngineConfiguration()
    • Method Detail

      • getEngineCfgKey

        public java.lang.String getEngineCfgKey()
        Specified by:
        getEngineCfgKey in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • getEngineScopeType

        public java.lang.String getEngineScopeType()
        Specified by:
        getEngineScopeType in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • createTransactionInterceptor

        public org.flowable.common.engine.impl.interceptor.CommandInterceptor createTransactionInterceptor()
        Specified by:
        createTransactionInterceptor in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initDbSqlSessionFactoryEntitySettings

        protected void initDbSqlSessionFactoryEntitySettings()
        Specified by:
        initDbSqlSessionFactoryEntitySettings in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initVariableTypes

        public void initVariableTypes()
      • getMyBatisXmlConfigurationStream

        public java.io.InputStream getMyBatisXmlConfigurationStream()
        Specified by:
        getMyBatisXmlConfigurationStream in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • getEngineName

        public java.lang.String getEngineName()
        Specified by:
        getEngineName in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • setTransactionSynchronizationAdapterOrder

        public void setTransactionSynchronizationAdapterOrder​(java.lang.Integer transactionSynchronizationAdapterOrder)
      • getServiceRegistryDataObjectOperations

        public DataObjectOperations getServiceRegistryDataObjectOperations()
      • setServiceRegistryDataObjectOperations

        public void setServiceRegistryDataObjectOperations​(DataObjectOperations serviceRegistryDataObjectOperations)
      • setDataSource

        public DataObjectEngineConfiguration setDataSource​(javax.sql.DataSource dataSource)
        Overrides:
        setDataSource in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • init

        protected void init()
      • initSessionFactories

        public void initSessionFactories()
        Overrides:
        initSessionFactories in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initServices

        protected void initServices()
      • initDataObjectDataSources

        protected void initDataObjectDataSources()
      • initTransactionContextFactory

        public void initTransactionContextFactory()
        Overrides:
        initTransactionContextFactory in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initDefaultCommandConfig

        public void initDefaultCommandConfig()
        Overrides:
        initDefaultCommandConfig in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initDataManagers

        public void initDataManagers()
        Overrides:
        initDataManagers in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initEntityManagers

        public void initEntityManagers()
        Overrides:
        initEntityManagers in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initSchemaManager

        public void initSchemaManager()
        Overrides:
        initSchemaManager in class org.flowable.common.engine.impl.AbstractEngineConfiguration
      • initSchemaManagementCommand

        public void initSchemaManagementCommand()
      • initDeployers

        protected void initDeployers()
      • getDefaultDeployers

        public java.util.Collection<? extends org.flowable.common.engine.impl.EngineDeployer> getDefaultDeployers()
      • initDataObjectDefinitionCache

        protected void initDataObjectDefinitionCache()
      • initDataObjectResourceConverter

        protected void initDataObjectResourceConverter()
      • initDeploymentManager

        protected void initDeploymentManager()
      • getTransactionManager

        public org.springframework.transaction.PlatformTransactionManager getTransactionManager()
        Specified by:
        getTransactionManager in interface org.flowable.common.spring.SpringEngineConfiguration
      • setTransactionManager

        public void setTransactionManager​(org.springframework.transaction.PlatformTransactionManager transactionManager)
        Specified by:
        setTransactionManager in interface org.flowable.common.spring.SpringEngineConfiguration
      • getNamedParameterJdbcOperations

        public org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations getNamedParameterJdbcOperations()
      • setNamedParameterJdbcOperations

        public void setNamedParameterJdbcOperations​(org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations namedParameterJdbcOperations)
      • getDeploymentName

        public java.lang.String getDeploymentName()
        Specified by:
        getDeploymentName in interface org.flowable.common.spring.SpringEngineConfiguration
      • setDeploymentName

        public void setDeploymentName​(java.lang.String deploymentName)
        Specified by:
        setDeploymentName in interface org.flowable.common.spring.SpringEngineConfiguration
      • getDeploymentResources

        public org.springframework.core.io.Resource[] getDeploymentResources()
        Specified by:
        getDeploymentResources in interface org.flowable.common.spring.SpringEngineConfiguration
      • setDeploymentResources

        public void setDeploymentResources​(org.springframework.core.io.Resource[] deploymentResources)
        Specified by:
        setDeploymentResources in interface org.flowable.common.spring.SpringEngineConfiguration
      • getApplicationContext

        public org.springframework.context.ApplicationContext getApplicationContext()
        Specified by:
        getApplicationContext in interface org.flowable.common.spring.SpringEngineConfiguration
      • setApplicationContext

        public void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)
        Specified by:
        setApplicationContext in interface org.springframework.context.ApplicationContextAware
        Specified by:
        setApplicationContext in interface org.flowable.common.spring.SpringEngineConfiguration
      • getDeploymentMode

        public java.lang.String getDeploymentMode()
        Specified by:
        getDeploymentMode in interface org.flowable.common.spring.SpringEngineConfiguration
      • setDeploymentMode

        public void setDeploymentMode​(java.lang.String deploymentMode)
        Specified by:
        setDeploymentMode in interface org.flowable.common.spring.SpringEngineConfiguration
      • getDataObjectEngineName

        public java.lang.String getDataObjectEngineName()
      • getDataObjectSchemaDefinitionDeployer

        public org.flowable.common.engine.impl.EngineDeployer getDataObjectSchemaDefinitionDeployer()
      • setDataObjectSchemaDefinitionDeployer

        public void setDataObjectSchemaDefinitionDeployer​(org.flowable.common.engine.impl.EngineDeployer dataObjectSchemaDefinitionDeployer)
      • getDataObjectDefinitionCacheLimit

        public int getDataObjectDefinitionCacheLimit()
      • setDataObjectDefinitionCacheLimit

        public DataObjectEngineConfiguration setDataObjectDefinitionCacheLimit​(int dataObjectDefinitionCacheLimit)
      • getDataObjectDefinitionCache

        public org.flowable.common.engine.impl.persistence.deploy.DeploymentCache<DataObjectDefinitionCacheEntry> getDataObjectDefinitionCache()
      • getVariableTypes

        public org.flowable.variable.api.types.VariableTypes getVariableTypes()
        Specified by:
        getVariableTypes in interface org.flowable.common.engine.impl.HasVariableTypes
      • setVariableTypes

        public DataObjectEngineConfiguration setVariableTypes​(org.flowable.variable.api.types.VariableTypes variableTypes)
        Specified by:
        setVariableTypes in interface org.flowable.common.engine.impl.HasVariableTypes
      • getCustomPreVariableTypes

        public java.util.List<org.flowable.variable.api.types.VariableType> getCustomPreVariableTypes()
      • setCustomPreVariableTypes

        public DataObjectEngineConfiguration setCustomPreVariableTypes​(java.util.List<org.flowable.variable.api.types.VariableType> customPreVariableTypes)
      • getCustomPostVariableTypes

        public java.util.List<org.flowable.variable.api.types.VariableType> getCustomPostVariableTypes()
      • setCustomPostVariableTypes

        public DataObjectEngineConfiguration setCustomPostVariableTypes​(java.util.List<org.flowable.variable.api.types.VariableType> customPostVariableTypes)
      • getDeploymentStrategies

        public java.util.Collection<org.flowable.common.spring.AutoDeploymentStrategy<DataObjectEngine>> getDeploymentStrategies()
      • setDeploymentStrategies

        public void setDeploymentStrategies​(java.util.Collection<org.flowable.common.spring.AutoDeploymentStrategy<DataObjectEngine>> deploymentStrategies)
      • start

        public void start()
        Specified by:
        start in interface org.springframework.context.Lifecycle
      • stop

        public void stop()
        Specified by:
        stop in interface org.springframework.context.Lifecycle
      • isRunning

        public boolean isRunning()
        Specified by:
        isRunning in interface org.springframework.context.Lifecycle
      • getPhase

        public int getPhase()
        Specified by:
        getPhase in interface org.springframework.context.Phased
        Specified by:
        getPhase in interface org.springframework.context.SmartLifecycle
        Specified by:
        getPhase in interface org.flowable.common.spring.SpringEngineConfiguration
      • setDataObjectRepositoryService

        public void setDataObjectRepositoryService​(DataObjectRepositoryService dataObjectRepositoryService)
      • isJsonVariableTypeTrackObjects

        public boolean isJsonVariableTypeTrackObjects()
      • setJsonVariableTypeTrackObjects

        public void setJsonVariableTypeTrackObjects​(boolean jsonVariableTypeTrackObjects)
      • setDataObjectRuntimeService

        public void setDataObjectRuntimeService​(DataObjectRuntimeService dataObjectRuntimeService)
      • setDataObjectDataSource

        public void setDataObjectDataSource​(DataObjectDataSource dataObjectDataSource)
      • getDataObjectDataSources

        public java.util.Map<java.lang.String,​DataObjectDataSource> getDataObjectDataSources()
      • registerDataObjectDataSource

        public void registerDataObjectDataSource​(DataObjectDataSource dataObjectDataSource)
      • autoDeployResources

        protected void autoDeployResources​(DataObjectEngine dataObjectEngine)
      • getAutoDeploymentStrategy

        public org.flowable.common.spring.AutoDeploymentStrategy<DataObjectEngine> getAutoDeploymentStrategy​(java.lang.String mode)
        Gets the AutoDeploymentStrategy for the provided mode. This method may be overridden to implement custom deployment strategies if required, but implementors should take care not to return null.
        Parameters:
        mode - the mode to get the strategy for
        Returns:
        the deployment strategy to use for the mode. Never null
      • isAutoUpdateDataObjectSchemaDefinitions

        public boolean isAutoUpdateDataObjectSchemaDefinitions()
      • setAutoUpdateDataObjectSchemaDefinitions

        public void setAutoUpdateDataObjectSchemaDefinitions​(boolean autoUpdateDataObjectSchemaDefinitions)