Search in sources :

Example 1 with MembershipEntityManagerFactory

use of org.activiti.engine.impl.persistence.MembershipEntityManagerFactory in project Activiti by Activiti.

the class ProcessEngineConfigurationImpl method initSessionFactories.

// session factories ////////////////////////////////////////////////////////
protected void initSessionFactories() {
    if (sessionFactories == null) {
        sessionFactories = new HashMap<Class<?>, SessionFactory>();
        if (dbSqlSessionFactory == null) {
            dbSqlSessionFactory = new DbSqlSessionFactory();
        }
        dbSqlSessionFactory.setDatabaseType(databaseType);
        dbSqlSessionFactory.setIdGenerator(idGenerator);
        dbSqlSessionFactory.setSqlSessionFactory(sqlSessionFactory);
        dbSqlSessionFactory.setDbIdentityUsed(isDbIdentityUsed);
        dbSqlSessionFactory.setDbHistoryUsed(isDbHistoryUsed);
        dbSqlSessionFactory.setDatabaseTablePrefix(databaseTablePrefix);
        dbSqlSessionFactory.setTablePrefixIsSchema(tablePrefixIsSchema);
        dbSqlSessionFactory.setDatabaseCatalog(databaseCatalog);
        dbSqlSessionFactory.setDatabaseSchema(databaseSchema);
        dbSqlSessionFactory.setBulkInsertEnabled(isBulkInsertEnabled, databaseType);
        dbSqlSessionFactory.setMaxNrOfStatementsInBulkInsert(maxNrOfStatementsInBulkInsert);
        addSessionFactory(dbSqlSessionFactory);
        addSessionFactory(new GenericManagerFactory(AttachmentEntityManager.class));
        addSessionFactory(new GenericManagerFactory(CommentEntityManager.class));
        addSessionFactory(new GenericManagerFactory(DeploymentEntityManager.class));
        addSessionFactory(new GenericManagerFactory(ModelEntityManager.class));
        addSessionFactory(new GenericManagerFactory(ExecutionEntityManager.class));
        addSessionFactory(new GenericManagerFactory(HistoricActivityInstanceEntityManager.class));
        addSessionFactory(new GenericManagerFactory(HistoricDetailEntityManager.class));
        addSessionFactory(new GenericManagerFactory(HistoricProcessInstanceEntityManager.class));
        addSessionFactory(new GenericManagerFactory(HistoricVariableInstanceEntityManager.class));
        addSessionFactory(new GenericManagerFactory(HistoricTaskInstanceEntityManager.class));
        addSessionFactory(new GenericManagerFactory(HistoricIdentityLinkEntityManager.class));
        addSessionFactory(new GenericManagerFactory(IdentityInfoEntityManager.class));
        addSessionFactory(new GenericManagerFactory(IdentityLinkEntityManager.class));
        addSessionFactory(new GenericManagerFactory(JobEntityManager.class));
        addSessionFactory(new GenericManagerFactory(ProcessDefinitionEntityManager.class));
        addSessionFactory(new GenericManagerFactory(ProcessDefinitionInfoEntityManager.class));
        addSessionFactory(new GenericManagerFactory(PropertyEntityManager.class));
        addSessionFactory(new GenericManagerFactory(ResourceEntityManager.class));
        addSessionFactory(new GenericManagerFactory(ByteArrayEntityManager.class));
        addSessionFactory(new GenericManagerFactory(TableDataManager.class));
        addSessionFactory(new GenericManagerFactory(TaskEntityManager.class));
        addSessionFactory(new GenericManagerFactory(VariableInstanceEntityManager.class));
        addSessionFactory(new GenericManagerFactory(EventSubscriptionEntityManager.class));
        addSessionFactory(new GenericManagerFactory(EventLogEntryEntityManager.class));
        addSessionFactory(new DefaultHistoryManagerSessionFactory());
        addSessionFactory(new UserEntityManagerFactory());
        addSessionFactory(new GroupEntityManagerFactory());
        addSessionFactory(new MembershipEntityManagerFactory());
    }
    if (customSessionFactories != null) {
        for (SessionFactory sessionFactory : customSessionFactories) {
            addSessionFactory(sessionFactory);
        }
    }
}
Also used : HistoricTaskInstanceEntityManager(org.activiti.engine.impl.persistence.entity.HistoricTaskInstanceEntityManager) EventSubscriptionEntityManager(org.activiti.engine.impl.persistence.entity.EventSubscriptionEntityManager) GroupEntityManagerFactory(org.activiti.engine.impl.persistence.GroupEntityManagerFactory) HistoricVariableInstanceEntityManager(org.activiti.engine.impl.persistence.entity.HistoricVariableInstanceEntityManager) UserEntityManagerFactory(org.activiti.engine.impl.persistence.UserEntityManagerFactory) EventLogEntryEntityManager(org.activiti.engine.impl.persistence.entity.EventLogEntryEntityManager) ExecutionEntityManager(org.activiti.engine.impl.persistence.entity.ExecutionEntityManager) DeploymentEntityManager(org.activiti.engine.impl.persistence.entity.DeploymentEntityManager) ResourceEntityManager(org.activiti.engine.impl.persistence.entity.ResourceEntityManager) CommentEntityManager(org.activiti.engine.impl.persistence.entity.CommentEntityManager) HistoricDetailEntityManager(org.activiti.engine.impl.persistence.entity.HistoricDetailEntityManager) GenericManagerFactory(org.activiti.engine.impl.persistence.GenericManagerFactory) HistoricVariableInstanceEntityManager(org.activiti.engine.impl.persistence.entity.HistoricVariableInstanceEntityManager) VariableInstanceEntityManager(org.activiti.engine.impl.persistence.entity.VariableInstanceEntityManager) SessionFactory(org.activiti.engine.impl.interceptor.SessionFactory) DefaultSqlSessionFactory(org.apache.ibatis.session.defaults.DefaultSqlSessionFactory) DefaultHistoryManagerSessionFactory(org.activiti.engine.impl.persistence.DefaultHistoryManagerSessionFactory) DbSqlSessionFactory(org.activiti.engine.impl.db.DbSqlSessionFactory) EntityManagerSessionFactory(org.activiti.engine.impl.variable.EntityManagerSessionFactory) SqlSessionFactory(org.apache.ibatis.session.SqlSessionFactory) JobEntityManager(org.activiti.engine.impl.persistence.entity.JobEntityManager) ProcessDefinitionInfoEntityManager(org.activiti.engine.impl.persistence.entity.ProcessDefinitionInfoEntityManager) DefaultHistoryManagerSessionFactory(org.activiti.engine.impl.persistence.DefaultHistoryManagerSessionFactory) ProcessDefinitionEntityManager(org.activiti.engine.impl.persistence.entity.ProcessDefinitionEntityManager) HistoricIdentityLinkEntityManager(org.activiti.engine.impl.persistence.entity.HistoricIdentityLinkEntityManager) IdentityLinkEntityManager(org.activiti.engine.impl.persistence.entity.IdentityLinkEntityManager) MembershipEntityManagerFactory(org.activiti.engine.impl.persistence.MembershipEntityManagerFactory) HistoricActivityInstanceEntityManager(org.activiti.engine.impl.persistence.entity.HistoricActivityInstanceEntityManager) IdentityInfoEntityManager(org.activiti.engine.impl.persistence.entity.IdentityInfoEntityManager) DbSqlSessionFactory(org.activiti.engine.impl.db.DbSqlSessionFactory) HistoricIdentityLinkEntityManager(org.activiti.engine.impl.persistence.entity.HistoricIdentityLinkEntityManager) PropertyEntityManager(org.activiti.engine.impl.persistence.entity.PropertyEntityManager) TableDataManager(org.activiti.engine.impl.persistence.entity.TableDataManager) TaskEntityManager(org.activiti.engine.impl.persistence.entity.TaskEntityManager) ModelEntityManager(org.activiti.engine.impl.persistence.entity.ModelEntityManager) HistoricProcessInstanceEntityManager(org.activiti.engine.impl.persistence.entity.HistoricProcessInstanceEntityManager) AttachmentEntityManager(org.activiti.engine.impl.persistence.entity.AttachmentEntityManager) ByteArrayEntityManager(org.activiti.engine.impl.persistence.entity.ByteArrayEntityManager)

Aggregations

DbSqlSessionFactory (org.activiti.engine.impl.db.DbSqlSessionFactory)1 SessionFactory (org.activiti.engine.impl.interceptor.SessionFactory)1 DefaultHistoryManagerSessionFactory (org.activiti.engine.impl.persistence.DefaultHistoryManagerSessionFactory)1 GenericManagerFactory (org.activiti.engine.impl.persistence.GenericManagerFactory)1 GroupEntityManagerFactory (org.activiti.engine.impl.persistence.GroupEntityManagerFactory)1 MembershipEntityManagerFactory (org.activiti.engine.impl.persistence.MembershipEntityManagerFactory)1 UserEntityManagerFactory (org.activiti.engine.impl.persistence.UserEntityManagerFactory)1 AttachmentEntityManager (org.activiti.engine.impl.persistence.entity.AttachmentEntityManager)1 ByteArrayEntityManager (org.activiti.engine.impl.persistence.entity.ByteArrayEntityManager)1 CommentEntityManager (org.activiti.engine.impl.persistence.entity.CommentEntityManager)1 DeploymentEntityManager (org.activiti.engine.impl.persistence.entity.DeploymentEntityManager)1 EventLogEntryEntityManager (org.activiti.engine.impl.persistence.entity.EventLogEntryEntityManager)1 EventSubscriptionEntityManager (org.activiti.engine.impl.persistence.entity.EventSubscriptionEntityManager)1 ExecutionEntityManager (org.activiti.engine.impl.persistence.entity.ExecutionEntityManager)1 HistoricActivityInstanceEntityManager (org.activiti.engine.impl.persistence.entity.HistoricActivityInstanceEntityManager)1 HistoricDetailEntityManager (org.activiti.engine.impl.persistence.entity.HistoricDetailEntityManager)1 HistoricIdentityLinkEntityManager (org.activiti.engine.impl.persistence.entity.HistoricIdentityLinkEntityManager)1 HistoricProcessInstanceEntityManager (org.activiti.engine.impl.persistence.entity.HistoricProcessInstanceEntityManager)1 HistoricTaskInstanceEntityManager (org.activiti.engine.impl.persistence.entity.HistoricTaskInstanceEntityManager)1 HistoricVariableInstanceEntityManager (org.activiti.engine.impl.persistence.entity.HistoricVariableInstanceEntityManager)1