public JVMClusterUtil.MasterThread addMaster(Configuration c, final int index) throws IOException { // Create each master with its own Configuration instance so each has // its HConnection instance rather than share (see HBASE_INSTANCES down in // the guts of HConnectionManager. JVMClusterUtil.MasterThread mt = JVMClusterUtil.createMasterThread(c, this.masterClass, index); this.masterThreads.add(mt); return mt; }
public JVMClusterUtil.RegionServerThread addRegionServer(Configuration config, final int index) throws IOException { // Create each regionserver with its own Configuration instance so each has // its HConnection instance rather than share (see HBASE_INSTANCES down in // the guts of HConnectionManager. JVMClusterUtil.RegionServerThread rst = JVMClusterUtil.createRegionServerThread(config, this.regionServerClass, index); this.regionThreads.add(rst); return rst; }
/** Shut down the mini HBase cluster */ public void shutdown() { JVMClusterUtil.shutdown(this.masterThreads, this.regionThreads); }
/** Start the cluster. */ public void startup() throws IOException { JVMClusterUtil.startup(this.masterThreads, this.regionThreads); }