Examples of disconnectSource()


Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      }
      case DISCONNECTSOURCE: {
         for (Cache<?, ?> cache : all ? getAllCaches(session) : Collections.singletonList(session.getCache(cacheName))) {
            RollingUpgradeManager upgradeManager = cache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
            try {
               upgradeManager.disconnectSource(migratorName);
               sb.append(MSG.disonnectedSource(migratorName, cache.getName()));
               sb.append("\n");
            } catch (Exception e) {
               throw log.sourceDisconnectionError(e, migratorName, cache.getName());
            }
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      RollingUpgradeManager targetUpgradeManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
      targetUpgradeManager.synchronizeData("hotrod");
      // The server contains one extra key: MIGRATION_MANAGER_HOT_ROD_KNOWN_KEYS
      assertEquals(sourceServerCache.size() - 1, targetServerCache.size());

      targetUpgradeManager.disconnectSource("hotrod");
      CacheLoaderManager loaderManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(CacheLoaderManager.class);
      assertFalse(loaderManager.isEnabled());
   }

   @BeforeMethod
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      RollingUpgradeManager targetUpgradeManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
      targetUpgradeManager.synchronizeData("hotrod");
      // The server contains one extra key: MIGRATION_MANAGER_HOT_ROD_KNOWN_KEYS
      assertEquals(sourceServerCache.size() - 1, targetServerCache.size());

      targetUpgradeManager.disconnectSource("hotrod");
      CacheLoaderManager loaderManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(CacheLoaderManager.class);
      assertFalse(loaderManager.isEnabled());
   }

   @BeforeMethod(alwaysRun = true)
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      sourceUpgradeManager.recordKnownGlobalKeyset();
      RollingUpgradeManager targetUpgradeManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
      targetUpgradeManager.synchronizeData("rest");
      assertEquals(sourceServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size(), targetServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size());

      targetUpgradeManager.disconnectSource("rest");
   }

   @BeforeMethod
   public void cleanup() {
      sourceServerCache.clear();
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      RollingUpgradeManager targetUpgradeManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
      targetUpgradeManager.synchronizeData("hotrod");
      // The server contains one extra key: MIGRATION_MANAGER_HOT_ROD_KNOWN_KEYS
      assertEquals(sourceServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size() - 1, targetServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size());

      targetUpgradeManager.disconnectSource("hotrod");
   }

   @BeforeMethod
   public void cleanup() {
      sourceServerCache.clear();
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

        @Override
        protected ModelNode invokeCommand(Cache<?, ?> cache, ModelNode operation) throws Exception {
            ComponentRegistry registry = SecurityActions.getComponentRegistry(cache.getAdvancedCache());
            RollingUpgradeManager manager = registry.getComponent(RollingUpgradeManager.class);
            if (manager != null) {
                manager.disconnectSource(operation.require(ModelKeys.MIGRATOR_NAME).asString());
            }
            return null;
        }
   }
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      RollingUpgradeManager targetUpgradeManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
      targetUpgradeManager.synchronizeData("hotrod");
      // The server contains one extra key: MIGRATION_MANAGER_HOT_ROD_KNOWN_KEYS
      assertEquals(sourceServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size() - 1, targetServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size());

      targetUpgradeManager.disconnectSource("hotrod");
      CacheLoaderManager loaderManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(CacheLoaderManager.class);
      assertFalse(loaderManager.isEnabled());
   }

   @BeforeMethod
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      sourceUpgradeManager.recordKnownGlobalKeyset();
      RollingUpgradeManager targetUpgradeManager = targetServerCache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
      targetUpgradeManager.synchronizeData("rest");
      assertEquals(sourceServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size(), targetServerCache.getAdvancedCache().withFlags(Flag.SKIP_CACHE_STORE).size());

      targetUpgradeManager.disconnectSource("rest");
   }

   @BeforeMethod
   public void cleanup() {
      sourceServerCache.clear();
View Full Code Here

Examples of org.infinispan.upgrade.RollingUpgradeManager.disconnectSource()

      }
      case DISCONNECTSOURCE: {
         for (Cache<?, ?> cache : all ? getAllCaches(session) : Collections.singletonList(session.getCache(cacheName))) {
            RollingUpgradeManager upgradeManager = cache.getAdvancedCache().getComponentRegistry().getComponent(RollingUpgradeManager.class);
            try {
               upgradeManager.disconnectSource(migratorName);
               sb.append(MSG.disonnectedSource(migratorName, cache.getName()));
               sb.append("\n");
            } catch (Exception e) {
               throw log.sourceDisconnectionError(e, cache.getName(), migratorName);
            }
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.