Package org.hibernate.cache.jbc.access

Examples of org.hibernate.cache.jbc.access.PutFromLoadValidator.invalidateRegion()


  private void nakedPutAfterRemovalTest(boolean transactional,
      boolean removeRegion) throws Exception {
    PutFromLoadValidator testee = new PutFromLoadValidator(
        transactional ? tm : null);
    if (removeRegion) {
      testee.invalidateRegion();
    } else {
      testee.invalidateKey(KEY1);
    }
    if (transactional) {
      tm.begin();
View Full Code Here


  private void registeredPutAfterRemovalTest(boolean transactional,
      boolean removeRegion) throws Exception {
    PutFromLoadValidator testee = new PutFromLoadValidator(
        transactional ? tm : null);
    if (removeRegion) {
      testee.invalidateRegion();
    } else {
      testee.invalidateKey(KEY1);
    }
    if (transactional) {
      tm.begin();
View Full Code Here

    if (transactional) {
      tm.begin();
    }
    testee.registerPendingPut(KEY1);
    if (removeRegion) {
      testee.invalidateRegion();
    } else {
      testee.invalidateKey(KEY1);
    }
   
    boolean lockable = testee.acquirePutFromLoadLock(KEY1);
View Full Code Here

  private void delayedNakedPutAfterRemovalTest(boolean transactional,
      boolean removeRegion) throws Exception {
    PutFromLoadValidator testee = new TestValidator(transactional ? tm
        : null, 100, 1000, 500, 10000);
    if (removeRegion) {
      testee.invalidateRegion();
    } else {
      testee.invalidateKey(KEY1);
    }
    if (transactional) {
      tm.begin();
View Full Code Here

    ExecutorService executor = Executors.newFixedThreadPool(3);
   
    // Start with a removal so the "isPutValid" calls will fail if
    // any of the concurrent activity isn't handled properly
   
    testee.invalidateRegion();
   
    // Do the registration + isPutValid calls
    executor.execute(r);
    executor.execute(r);
    executor.execute(r);
View Full Code Here

            removeLatch.await();
            if (keyOnly) {
              testee.invalidateKey(KEY1);
            }
            else {
              testee.invalidateRegion();
            }           
            cache.set(null);
            return null;
        }
      };
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.