Examples of startEviction()


Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

            e.printStackTrace();
         }
      }

      EvictionController evictionController = new EvictionController(cache);
      evictionController.startEviction();

      String str1 = rootStr + "7";
      Fqn fqn1 = Fqn.fromString(str1);
      String str2 = rootStr + "7/7";
      Fqn fqn2 = Fqn.fromString(str2);
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

      try
      {
         assertNotNull(cache.get(fqn2, str2));
         assertNotNull(cache.get(fqn1, str1));
         cache.removeNode(fqn2);
         evictionController.startEviction();
         assertNull(cache.get(fqn2, str2));
         assertNotNull(cache.get(fqn1, str1));
         cache.removeNode(fqn1);
         evictionController.startEviction();
         assertNull(cache.get(fqn1, str1));
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

         cache.removeNode(fqn2);
         evictionController.startEviction();
         assertNull(cache.get(fqn2, str2));
         assertNotNull(cache.get(fqn1, str1));
         cache.removeNode(fqn1);
         evictionController.startEviction();
         assertNull(cache.get(fqn1, str1));
         assertNull(cache.get(fqn2, str2));

         String str3 = rootStr + "5/5";
         String str4 = rootStr + "5";
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

         Fqn fqn3 = Fqn.fromString(str3);
         Fqn fqn4 = Fqn.fromString(str4);
         assertNotNull(cache.get(fqn3, str3));
         assertNotNull(cache.get(fqn4, str4));

         evictionController.startEviction();

         // remove the node above fqn4 /org/jboss/test/5 will cascade the delete into /org/jboss/test/5/5
         cache.removeNode(fqn4);

         evictionController.startEviction();
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

         evictionController.startEviction();

         // remove the node above fqn4 /org/jboss/test/5 will cascade the delete into /org/jboss/test/5/5
         cache.removeNode(fqn4);

         evictionController.startEviction();
         assertNull(cache.get(fqn3, str3));
         assertNull(cache.get(fqn4, str4));
      }
      catch (Exception e)
      {
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

            }
         }
      }

      EvictionController ec1 = new EvictionController(cache1);
      ec1.startEviction();
      int childrenSize = cache1.getRoot().getChild(Fqn.fromString("/org/jboss/data")).getChildren().size();
      assert childrenSize == 5000 : "Expected 5000, saw " + childrenSize;

      c = UnitTestCacheConfigurationFactory.createConfiguration(CacheMode.REPL_SYNC, true);
      additionalConfiguration(c);
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

      assertTrue("Saw base decrease", sawBaseDecrease);
      assertNull("No exceptions in p1", p1.ex);
      assertNull("No exceptions in p2", p2.ex);

      EvictionController ec2 = new EvictionController(cache2);
      ec2.startEviction();

      parent = cache2.getRoot().getChild(Fqn.fromString("/org/jboss/test/data"));
      children = parent.getChildren();
      if (children != null)
      {
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

      final Cache<Object, Object> cache2 = new UnitTestCacheFactory<Object, Object>().createCache(c, getClass());
      EvictionController ec2 = new EvictionController(cache2);
      caches.put("evict2", cache2);

      assert cache2.getRoot().getChild(Fqn.fromString("/org/jboss/test/data/")).getChildren().size() == 10;
      ec2.startEviction();
      assert cache2.getRoot().getChild(Fqn.fromString("/org/jboss/test/data/")).getChildren().size() == 5;
   }

   private class CacheActivator extends CacheUser
   {
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

            fail("Failed to insert data" + e);
            e.printStackTrace();
         }
      }
      EvictionController evictionController = new EvictionController(cache);
      evictionController.startEviction();

      try
      {
         String val = (String) cache.get(rootStr + "3", rootStr + "3");
         assertNull("DataNode should be empty ", val);
View Full Code Here

Examples of org.jboss.cache.util.internals.EvictionController.startEviction()

         Fqn fqn = Fqn.fromString(str);
         cache.put(fqn, str, str);
      }

      EvictionController evictionController = new EvictionController(cache);
      evictionController.startEviction();
      // wait a few secs for eviction to complete
//      TestingUtil.sleepThread(500);
      assertEquals("Number of nodes", maxNodes + 2, cache.getNumberOfNodes());
      for (int i = 0; i < maxNodes; i++)
      {
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.