Search in sources :

Example 1 with TransactionManager

use of org.jaffa.loader.transaction.TransactionManager in project jaffa-framework by jaffa-projects.

the class RepositoryJsonServiceTest method setUp.

/**
 * This setup function registers resources to each managed repository to produce correct retrieval results
 * @throws Exception
 */
@Before
public void setUp() throws Exception {
    managerRepositoryService = ManagerRepositoryService.getInstance();
    ContextKey testKey = new ContextKey("testKey", "file1.xml", "NULL", "1-PRODUCT");
    SchedulerManager testManager = new SchedulerManager();
    Task testTask = new Task();
    repositoryJsonService = new RepositoryJsonService();
    testKey = new ContextKey("testKey", "file1.xml", "NULL", "1-PRODUCT");
    testManager = new SchedulerManager();
    testTask = new Task();
    // Must populate a repository element in order to retrieve data
    testTask.setAutoCreateDataBean(true);
    testTask.setDataBean("DataBeanTest");
    testTask.setType("TestType");
    testManager.registerSchedulerTask(testKey, testTask);
    // Add managers to ManagerRepositoryService
    managerRepositoryService.add("Task", testManager);
    managerRepositoryService.add("ComponentManager", new ComponentManager());
    managerRepositoryService.add("ApplicationRulesManager", new ApplicationRulesManager());
    managerRepositoryService.add("NavigationManager", new NavigationManager());
    managerRepositoryService.add("BusinessFunctionManager", new BusinessFunctionManager());
    managerRepositoryService.add("RoleManager", new RoleManager());
    managerRepositoryService.add("JndiJmsManager", new JndiJmsManager());
    managerRepositoryService.add("MessagingManager", new MessagingManager());
    managerRepositoryService.add("SoaEventManager", new SoaEventManager());
    managerRepositoryService.add("TransactionManager", new TransactionManager());
}
Also used : NavigationManager(org.jaffa.loader.navigation.NavigationManager) Task(org.jaffa.modules.scheduler.services.configdomain.Task) RoleManager(org.jaffa.loader.policy.RoleManager) JndiJmsManager(org.jaffa.loader.messaging.JndiJmsManager) MessagingManager(org.jaffa.loader.messaging.MessagingManager) SchedulerManager(org.jaffa.loader.scheduler.SchedulerManager) BusinessFunctionManager(org.jaffa.loader.policy.BusinessFunctionManager) ApplicationRulesManager(org.jaffa.loader.config.ApplicationRulesManager) SoaEventManager(org.jaffa.loader.soa.SoaEventManager) RepositoryJsonService(org.jaffa.api.services.monitoring.controller.RepositoryJsonService) TransactionManager(org.jaffa.loader.transaction.TransactionManager) ComponentManager(org.jaffa.loader.components.ComponentManager) Before(org.junit.Before)

Example 2 with TransactionManager

use of org.jaffa.loader.transaction.TransactionManager in project jaffa-framework by jaffa-projects.

the class RepositoryJsonServiceTest method setUp.

/**
 * This setup function registers resources to each managed repository to produce correct retrieval results
 * @throws Exception
 */
@Before
public void setUp() throws Exception {
    managerRepositoryService = ManagerRepositoryService.getInstance();
    repositoryJsonService = new RepositoryJsonService();
    testKey = new ContextKey("testKey", "file1.xml", "NULL", "1-PRODUCT");
    testManager = new SchedulerManager();
    testTask = new Task();
    // Must populate a repository element in order to retrieve data
    testTask.setAutoCreateDataBean(true);
    testTask.setDataBean("DataBeanTest");
    testTask.setType("TestType");
    testManager.registerSchedulerTask(testKey, testTask);
    // Add managers to ManagerRepositoryService
    managerRepositoryService.add("Task", testManager);
    managerRepositoryService.add("ComponentManager", new ComponentManager());
    managerRepositoryService.add("ApplicationRulesManager", new ApplicationRulesManager());
    managerRepositoryService.add("NavigationManager", new NavigationManager());
    managerRepositoryService.add("BusinessFunctionManager", new BusinessFunctionManager());
    managerRepositoryService.add("RoleManager", new RoleManager());
    managerRepositoryService.add("JndiJmsManager", new JndiJmsManager());
    managerRepositoryService.add("MessagingManager", new MessagingManager());
    managerRepositoryService.add("SoaEventManager", new SoaEventManager());
    managerRepositoryService.add("TransactionManager", new TransactionManager());
}
Also used : NavigationManager(org.jaffa.loader.navigation.NavigationManager) Task(org.jaffa.modules.scheduler.services.configdomain.Task) RoleManager(org.jaffa.loader.policy.RoleManager) JndiJmsManager(org.jaffa.loader.messaging.JndiJmsManager) MessagingManager(org.jaffa.loader.messaging.MessagingManager) SchedulerManager(org.jaffa.loader.scheduler.SchedulerManager) BusinessFunctionManager(org.jaffa.loader.policy.BusinessFunctionManager) ApplicationRulesManager(org.jaffa.loader.config.ApplicationRulesManager) SoaEventManager(org.jaffa.loader.soa.SoaEventManager) ContextKey(org.jaffa.loader.ContextKey) TransactionManager(org.jaffa.loader.transaction.TransactionManager) ComponentManager(org.jaffa.loader.components.ComponentManager) Before(org.junit.Before)

Example 3 with TransactionManager

use of org.jaffa.loader.transaction.TransactionManager in project jaffa-framework by jaffa-projects.

the class SoaLoaderConfig method jaffaTransactionManager.

@Bean
public TransactionManager jaffaTransactionManager() {
    TransactionManager transactionManager = new TransactionManager();
    org.jaffa.transaction.services.ConfigurationService.setTransactionManager(transactionManager);
    return transactionManager;
}
Also used : TransactionManager(org.jaffa.loader.transaction.TransactionManager) Bean(org.springframework.context.annotation.Bean)

Aggregations

TransactionManager (org.jaffa.loader.transaction.TransactionManager)3 ComponentManager (org.jaffa.loader.components.ComponentManager)2 ApplicationRulesManager (org.jaffa.loader.config.ApplicationRulesManager)2 JndiJmsManager (org.jaffa.loader.messaging.JndiJmsManager)2 MessagingManager (org.jaffa.loader.messaging.MessagingManager)2 NavigationManager (org.jaffa.loader.navigation.NavigationManager)2 BusinessFunctionManager (org.jaffa.loader.policy.BusinessFunctionManager)2 RoleManager (org.jaffa.loader.policy.RoleManager)2 SchedulerManager (org.jaffa.loader.scheduler.SchedulerManager)2 SoaEventManager (org.jaffa.loader.soa.SoaEventManager)2 Task (org.jaffa.modules.scheduler.services.configdomain.Task)2 Before (org.junit.Before)2 RepositoryJsonService (org.jaffa.api.services.monitoring.controller.RepositoryJsonService)1 ContextKey (org.jaffa.loader.ContextKey)1 Bean (org.springframework.context.annotation.Bean)1