Package org.apache.hadoop.hbase.client

Examples of org.apache.hadoop.hbase.client.Admin.compactRegion()


        try {
          HRegion region = TEST_UTIL.getSplittableRegion(tableName, -1);
          if (region != null) {
            byte[] regionName = region.getRegionName();
            admin.flushRegion(regionName);
            admin.compactRegion(regionName);
            admin.splitRegion(regionName);
          } else {
            LOG.warn("Could not find suitable region for the table.  Possibly the " +
              "region got closed and the attempts got over before " +
              "the region could have got reassigned.");
View Full Code Here


      if (major) {
        LOG.debug("Major compacting region " + region.getRegionNameAsString());
        admin.majorCompactRegion(region.getRegionName());
      } else {
        LOG.debug("Compacting region " + region.getRegionNameAsString());
        admin.compactRegion(region.getRegionName());
      }
    } catch (Exception ex) {
      LOG.warn("Compaction failed, might be caused by other chaos: " + ex.getMessage());
    }
    if (sleepTime > 0) {
View Full Code Here

        try {
          HRegion region = TEST_UTIL.getSplittableRegion(tableName, -1);
          if (region != null) {
            byte[] regionName = region.getRegionName();
            admin.flushRegion(regionName);
            admin.compactRegion(regionName);
            admin.splitRegion(regionName);
          } else {
            LOG.warn("Could not find suitable region for the table.  Possibly the " +
              "region got closed and the attempts got over before " +
              "the region could have got reassigned.");
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.