Examples of quiesceStandby()


Examples of org.apache.hadoop.hdfs.server.namenode.AvatarNode.quiesceStandby()

    cluster.restartAvatarNodes(); //49 (restart + initial checkpoint)
    primary = cluster.getPrimaryAvatar(0).avatar;
    standby = cluster.getStandbyAvatar(0).avatar;
    createEdits(20);
    standby.quiesceStandby(getCurrentTxId(primary)-1);
     assertEquals(69, getCurrentTxId(primary));
     assertEquals(getCurrentTxId(primary), getCurrentTxId(standby));
    InjectionHandler.clear();
  }
 
View Full Code Here

Examples of org.apache.hadoop.hdfs.server.namenode.AvatarNode.quiesceStandby()

    // some incorrect option
    runAndAssertCommand(shell, -1, new String[] { "-one", "-saveNamespace",
        "someOption" });

    standby.quiesceStandby(DFSAvatarTestUtil.getCurrentTxId(primary) - 1);
    // edits + SLS + 2 * 2(for each successful checkpoint)
    assertEquals(45, DFSAvatarTestUtil.getCurrentTxId(primary));
  }
}
View Full Code Here

Examples of org.apache.hadoop.hdfs.server.namenode.AvatarNode.quiesceStandby()

    // another roll adds 2 transactions
    assertEquals(29, getCurrentTxId(primary));
   
    if (!enableQJM) {
      createEdits(20);
      standby.quiesceStandby(getCurrentTxId(primary)-1);
      assertEquals(49, getCurrentTxId(primary));
      assertEquals(getCurrentTxId(primary), getCurrentTxId(standby));
    }
  }
 
View Full Code Here

Examples of org.apache.hadoop.hdfs.server.namenode.AvatarNode.quiesceStandby()

    // roll adds two transactions
    assertEquals(29, getCurrentTxId(primary));
   
    if (!enableQJM) {
      createEdits(20);
      standby.quiesceStandby(getCurrentTxId(primary)-1);
      assertEquals(49, getCurrentTxId(primary));
      assertEquals(getCurrentTxId(primary), getCurrentTxId(standby));
    }
  }
 
View Full Code Here

Examples of org.apache.hadoop.hdfs.server.namenode.AvatarNode.quiesceStandby()

      LOG.info("Waiting for event : " + stopOnEvent);
      Thread.sleep(1000);
    }
   
    if (!enableQJM) {
      standby.quiesceStandby(getCurrentTxId(primary)-1);
      // only assert this for FileJournalManager.
      // edits + SLS + ELS + SLS (checkpoint fails, but roll happened)
      assertEquals(43, getCurrentTxId(primary));
     
      // if quiesce happened before roll, the standby will be behind by 1 transaction
View Full Code Here

Examples of org.apache.hadoop.hdfs.server.namenode.AvatarNode.quiesceStandby()

      // if quiesce happened before roll, the standby will be behind by 1 transaction
      // which will be reclaimed by opening the log after
      long extraTransaction = rollAfterQuiesce ? 1 : 0;
      assertEquals(getCurrentTxId(primary), getCurrentTxId(standby) + extraTransaction);
    } else {
      standby.quiesceStandby(FSEditLogLoader.TXID_IGNORE);
    }
   
    // make sure the checkpoint indeed failed
    assertTrue(h.receivedEvents
        .contains(InjectionEvent.STANDBY_EXIT_CHECKPOINT_EXCEPTION));
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.