Examples of rewire()


Examples of org.infinispan.factories.GlobalComponentRegistry.rewire()

   public static <T> T replaceComponent(CacheContainer cacheContainer, Class<T> componentType, T replacementComponent, boolean rewire) {
      GlobalComponentRegistry cr = extractGlobalComponentRegistry(cacheContainer);
      T old = cr.getComponent(componentType);
      cr.registerComponent(replacementComponent, componentType);
      if (rewire) {
         cr.rewire();
         cr.rewireNamedRegistries();
      }
      return old;
   }
View Full Code Here

Examples of org.infinispan.factories.GlobalComponentRegistry.rewire()

   public static <T> T replaceComponent(CacheContainer cacheContainer, Class<T> componentType, T replacementComponent, boolean rewire) {
      GlobalComponentRegistry cr = extractGlobalComponentRegistry(cacheContainer);
      T old = cr.getComponent(componentType);
      cr.registerComponent(replacementComponent, componentType);
      if (rewire) {
         cr.rewire();
         cr.rewireNamedRegistries();
      }
      return old;
   }
View Full Code Here

Examples of org.infinispan.factories.GlobalComponentRegistry.rewire()

   public static <T> T replaceComponent(CacheContainer cacheContainer, Class<T> componentType, T replacementComponent, boolean rewire) {
      GlobalComponentRegistry cr = extractGlobalComponentRegistry(cacheContainer);
      T old = cr.getComponent(componentType);
      cr.registerComponent(replacementComponent, componentType);
      if (rewire) {
         cr.rewire();
         cr.rewireNamedRegistries();
      }
      return old;
   }
View Full Code Here

Examples of org.jboss.cache.factories.ComponentRegistry.rewire()

      DelegatingRPCManager delegatingRPCManager = new DelegatingRPCManager();
      ComponentRegistry cr = TestingUtil.extractComponentRegistry(c1);
      RPCManager origRpcManager = cr.getComponent(RPCManager.class);
      delegatingRPCManager.delegate = origRpcManager;
      cr.registerComponent(delegatingRPCManager, RPCManager.class);
      cr.rewire();

      c1.getTransactionManager().begin();
      c1.put("/a", "k", "v");
      c1.getTransactionManager().commit();
View Full Code Here

Examples of org.jboss.cache.factories.ComponentRegistry.rewire()

   {
      ComponentRegistry cr = crTL.get();
      if (cr.getState() == CacheStatus.STARTED) cr.stop();
      cr.registerComponent(rm, RegionManager.class);
      cr.create();
      cr.rewire();
      // force cache mode
      VersionAwareMarshaller m = (VersionAwareMarshaller) cr.getComponent(Marshaller.class);
      m.init();
      m.initReplicationVersions();
      return m;
View Full Code Here

Examples of org.jboss.cache.factories.ComponentRegistry.rewire()

      List<Address> memberList = originalRpcManager.getMembers();
      expect(rpcManager.getMembers()).andReturn(memberList).anyTimes();
      // inject a mock RPC manager so that we can test whether calls made are sync or async.
      ComponentRegistry cr = TestingUtil.extractComponentRegistry(tl.cache1);
      cr.registerComponent(rpcManager, RPCManager.class);
      cr.rewire();

      // invalidations will not trigger any rpc calls for PFER
      if (!isUsingInvalidation())
      {
         // specify what we expect called on the mock Rpc Manager.  For params we don't care about, just use ANYTHING.
View Full Code Here

Examples of org.jboss.cache.factories.ComponentRegistry.rewire()

      c.setInactiveOnStartup(false);
      c.setUseRegionBasedMarshalling(true);
      c.setCacheMarshaller(cm200);
      ComponentRegistry cr = crTL.get();     
      cr.registerComponent(cm200, CacheMarshaller200.class);
      cr.rewire();
      cr.start();

      RegionManager rm = cr.getComponent(RegionManager.class);
      ByteArrayOutputStream baos = new ByteArrayOutputStream();
      ObjectOutputStream oos = new ObjectOutputStream(baos);
View Full Code Here

Examples of org.jboss.cache.factories.ComponentRegistry.rewire()

      List<Address> memberList = rpcManager1.getMembers();
      expect(rpcManager.getMembers()).andReturn(memberList).anyTimes();
      // inject a mock RPC manager so that we can test whether calls made are sync or async.
      ComponentRegistry cr = TestingUtil.extractComponentRegistry(cache1);
      cr.registerComponent(rpcManager, RPCManager.class);
      cr.rewire();

      // invalidations will not trigger any rpc calls for PFER
      if (!isUsingInvalidation())
      {
         // specify what we expectWithTx called on the mock Rpc Manager.  For params we don't care about, just use ANYTHING.
View Full Code Here

Examples of org.jboss.cache.factories.ComponentRegistry.rewire()

      c.setInactiveOnStartup(false);
      c.setUseRegionBasedMarshalling(true);
      c.setCacheMarshaller(cm200);
      ComponentRegistry cr = this.cr;
      cr.registerComponent(cm200, CacheMarshaller200.class);
      cr.rewire();
      cr.start();

      RegionManager rm = cr.getComponent(RegionManager.class);
      ByteArrayOutputStream baos = new ByteArrayOutputStream();
      ObjectOutputStream oos = new ObjectOutputStream(baos);
View Full Code Here

Examples of org.jboss.cache.factories.ComponentRegistry.rewire()

      DelegatingRPCManager delegatingRPCManager = new DelegatingRPCManager();
      ComponentRegistry cr = TestingUtil.extractComponentRegistry(c1);
      RPCManager origRpcManager = cr.getComponent(RPCManager.class);
      delegatingRPCManager.delegate = origRpcManager;
      cr.registerComponent(delegatingRPCManager, RPCManager.class);
      cr.rewire();

      c1.getTransactionManager().begin();
      c1.put("/a", "k", "v");
      c1.getTransactionManager().commit();
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.