Examples of CacheFactoryRegistry


Examples of org.castor.cache.CacheFactoryRegistry

                      final ClassDescriptorResolver cdResolver,
                      final PersistenceFactory persistenceFactory)
    throws MappingException {
        if (_cacheFactoryRegistry == null) {
            AbstractProperties properties = CPAProperties.getInstance();
            _cacheFactoryRegistry = new CacheFactoryRegistry(properties);
        }
       
        _connectionFactory = connectionFactory;
        _persistenceFactory = persistenceFactory;
       
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

      {
         return;
      }
     
      Cache cacheConfig = getAnnotation(Cache.class);
      CacheFactoryRegistry registry = getCacheFactoryRegistry();
      Ejb3CacheFactory factory = registry.getCacheFactory(cacheConfig.value());
      this.cache = factory.createCache();
      this.cache.initialize(this);
      this.cache.start();
   }
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

      {
         return;
      }
     
      Cache cacheConfig = getAnnotation(Cache.class);
      CacheFactoryRegistry registry = getCacheFactoryRegistry();
      Ejb3CacheFactory factory = registry.getCacheFactory(cacheConfig.value());
      this.cache = factory.createCache();
      this.cache.initialize(this);
      this.cache.start();
   }
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

      {
         return;
      }

      Cache cacheConfig = getAnnotation(Cache.class);
      CacheFactoryRegistry registry = getCacheFactoryRegistry();
      Ejb3CacheFactory factory = registry.getCacheFactory(cacheConfig.value());
      this.cache = factory.createCache();
      this.cache.initialize(this);
      this.cache.start();
   }
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

      {
         return;
      }

      Cache cacheConfig = getAnnotation(Cache.class);
      CacheFactoryRegistry registry = getCacheFactoryRegistry();
      Ejb3CacheFactory factory = registry.getCacheFactory(cacheConfig.value());
      this.cache = factory.createCache();
      this.cache.initialize(this);
      this.cache.start();
   }
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

   }
  
   @AfterClass
   public static void afterClass() throws Exception
   {
      CacheFactoryRegistry cacheFactoryRegistry = Ejb3RegistrarLocator.locateRegistrar().lookup("EJB3CacheFactoryRegistry", CacheFactoryRegistry.class);
      cacheFactoryRegistry.getFactories().remove(TestCacheFactory.NAME);
     
      AbstractEJB3TestCase.afterClass();
   }
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

   public static void beforeClass() throws Exception
   {
      AbstractEJB3TestCase.beforeClass();
     
      // Add the Force Passivation Cache
      CacheFactoryRegistry cacheFactoryRegistry = Ejb3RegistrarLocator.locateRegistrar().lookup("EJB3CacheFactoryRegistry", CacheFactoryRegistry.class);
      cacheFactoryRegistry.getFactories().put(TestCacheFactory.NAME, TestCacheFactory.class);
      //log.info("Added " + forcePassivationCacheRegistryName);

      deploySessionEjb(PassivatingStatefulBean.class);
   }
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

      HashMap<String, Class<? extends PoolFactory>> poolFactories = new HashMap<String, Class<? extends PoolFactory>>();
      poolFactories.put("ThreadlocalPool", ThreadlocalPoolFactory.class);
      poolFactories.put("StrictMaxPool", StrictMaxPoolFactory.class);
      poolRegistry.setFactories(poolFactories);
      setPoolFactoryRegistry(poolRegistry);
      CacheFactoryRegistry cacheRegistry = new CacheFactoryRegistry();
      HashMap<String, Class<? extends Ejb3CacheFactory>> cacheFactories = new HashMap<String, Class<? extends Ejb3CacheFactory>>();
      cacheFactories.put("NoPassivationCache", NoPassivationCacheFactory.class);
      cacheFactories.put("SimpleStatefulCache", SimpleStatefulCacheFactory.class);
      cacheFactories.put("StatefulTreeCache", StatefulTreeCacheFactory.class);
      cacheRegistry.setFactories(cacheFactories);
      setCacheFactoryRegistry(cacheRegistry);
   }
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

         if (sessionType.equals(ContainerType.SFSB))
         {
            // Lookup Factory Registries in MC
            PersistenceManagerFactoryRegistry registry = Ejb3RegistrarLocator.locateRegistrar().lookup(
                  AbstractEJB3TestCase.OBJECT_STORE_NAME_PM_FACTORY_REGISTRY, PersistenceManagerFactoryRegistry.class);
            CacheFactoryRegistry cacheFactoryRegistry = Ejb3RegistrarLocator.locateRegistrar().lookup(
                  AbstractEJB3TestCase.OBJECT_STORE_NAME_CACHE_FACTORY_REGISTRY, CacheFactoryRegistry.class);

            // Set on the deployment
            deployment.setPersistenceManagerFactoryRegistry(registry);
            deployment.setCacheFactoryRegistry(cacheFactoryRegistry);
View Full Code Here

Examples of org.jboss.ejb3.cache.CacheFactoryRegistry

      {
         return;
      }

      Cache cacheConfig = getAnnotation(Cache.class);
      CacheFactoryRegistry registry = getCacheFactoryRegistry();
      Ejb3CacheFactory factory = registry.getCacheFactory(cacheConfig.value());
      this.cache = factory.createCache();
      this.cache.initialize(this);
      this.cache.start();
   }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.