Examples of CatalogTracker


Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

   * <code> host187.example.com,60020,1289493121758</code>
   * @throws IOException if a remote or network exception occurs
   */
  public void closeRegion(final byte [] regionname, final String serverName)
  throws IOException {
    CatalogTracker ct = getCatalogTracker();
    try {
      if (serverName != null) {
        Pair<HRegionInfo, ServerName> pair = MetaReader.getRegion(ct, regionname);
        if (pair == null || pair.getFirst() == null) {
          LOG.info("No region in .META. for " +
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

   * @throws IOException if a remote or network exception occurs
   * @throws InterruptedException
   */
  public void flush(final byte [] tableNameOrRegionName)
  throws IOException, InterruptedException {
    CatalogTracker ct = getCatalogTracker();
    boolean isRegionName = isRegionName(tableNameOrRegionName, ct);
    try {
      if (isRegionName) {
        Pair<HRegionInfo, ServerName> pair =
          MetaReader.getRegion(ct, tableNameOrRegionName);
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

   * @throws IOException if a remote or network exception occurs
   * @throws InterruptedException
   */
  private void compact(final byte [] tableNameOrRegionName, final boolean major)
  throws IOException, InterruptedException {
    CatalogTracker ct = getCatalogTracker();
    try {
      if (isRegionName(tableNameOrRegionName, ct)) {
        Pair<HRegionInfo, ServerName> pair =
          MetaReader.getRegion(ct, tableNameOrRegionName);
        if (pair == null || pair.getSecond() == null) {
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

   * @throws IOException if a remote or network exception occurs
   * @throws InterruptedException interrupt exception occurred
   */
  public void split(final byte [] tableNameOrRegionName,
      final byte [] splitPoint) throws IOException, InterruptedException {
    CatalogTracker ct = getCatalogTracker();
    try {
      if (isRegionName(tableNameOrRegionName, ct)) {
        // Its a possible region name.
        Pair<HRegionInfo, ServerName> pair =
          MetaReader.getRegion(ct, tableNameOrRegionName);
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

   * @return Ordered list of {@link HRegionInfo}.
   * @throws IOException
   */ 
  public List<HRegionInfo> getTableRegions(final byte[] tableName)
  throws IOException {
    CatalogTracker ct = getCatalogTracker();
    List<HRegionInfo> Regions = null;
    try {
      Regions = MetaReader.getTableRegions(ct, tableName, true);
    } finally {
      cleanupCatalogTracker(ct);
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

   * @return the current compaction state
   */
  public CompactionState getCompactionState(final byte [] tableNameOrRegionName)
      throws IOException, InterruptedException {
    CompactionState state = CompactionState.NONE;
    CatalogTracker ct = getCatalogTracker();
    try {
      if (isRegionName(tableNameOrRegionName, ct)) {
        Pair<HRegionInfo, ServerName> pair =
          MetaReader.getRegion(ct, tableNameOrRegionName);
        if (pair == null || pair.getSecond() == null) {
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

    // Create and startup an executor.  This is used by AssignmentManager
    // handling zk callbacks.
    ExecutorService executor = startupMasterExecutor("testBalanceExecutor");

    // We need a mocked catalog tracker.
    CatalogTracker ct = Mockito.mock(CatalogTracker.class);
    LoadBalancer balancer = LoadBalancerFactory.getLoadBalancer(server
        .getConfiguration());
    // Create an AM.
    AssignmentManager am = new AssignmentManager(this.server,
      this.serverManager, ct, balancer, executor, null, master.getTableLockManager());
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

    // Create and startup an executor.  This is used by AssignmentManager
    // handling zk callbacks.
    ExecutorService executor = startupMasterExecutor("testShutdownHandler");

    // We need a mocked catalog tracker.
    CatalogTracker ct = Mockito.mock(CatalogTracker.class);
    // Create an AM.
    AssignmentManagerWithExtrasForTesting am = setUpMockedAssignmentManager(
        this.server, this.serverManager);
    try {
      processServerShutdownHandler(ct, am, false);
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

      IOException, NodeExistsException, InterruptedException, ServiceException {
    // Create and startup an executor. This is used by AssignmentManager
    // handling zk callbacks.
    ExecutorService executor = startupMasterExecutor("testSSHWhenSplitRegionInProgress");
    // We need a mocked catalog tracker.
    CatalogTracker ct = Mockito.mock(CatalogTracker.class);
    ZKAssign.deleteAllNodes(this.watcher);

    // Create an AM.
    AssignmentManagerWithExtrasForTesting am = setUpMockedAssignmentManager(
      this.server, this.serverManager);
View Full Code Here

Examples of org.apache.hadoop.hbase.catalog.CatalogTracker

      IOException, NodeExistsException, ServiceException {
    // Create and startup an executor. This is used by AssignmentManager
    // handling zk callbacks.
    ExecutorService executor = startupMasterExecutor("testSSHWhenDisableTableInProgress");
    // We need a mocked catalog tracker.
    CatalogTracker ct = Mockito.mock(CatalogTracker.class);
    LoadBalancer balancer = LoadBalancerFactory.getLoadBalancer(server.getConfiguration());
    ZKAssign.deleteAllNodes(this.watcher);

    // Create an AM.
    AssignmentManager am = new AssignmentManager(this.server,
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.