use of org.apache.hadoop.hbase.master.MasterCoprocessorHost in project hbase by apache.
the class CreateTableProcedure method postCreate.
private void postCreate(final MasterProcedureEnv env) throws IOException, InterruptedException {
final MasterCoprocessorHost cpHost = env.getMasterCoprocessorHost();
if (cpHost != null) {
final HRegionInfo[] regions = (newRegions == null) ? null : newRegions.toArray(new HRegionInfo[newRegions.size()]);
cpHost.postCompletedCreateTableAction(hTableDescriptor, regions, getUser());
}
}
use of org.apache.hadoop.hbase.master.MasterCoprocessorHost in project hbase by apache.
the class TestCoprocessorConfiguration method testMasterCoprocessorHostDefaults.
@Test
public void testMasterCoprocessorHostDefaults() throws Exception {
Configuration conf = new Configuration(CONF);
MasterServices masterServices = mock(MasterServices.class);
systemCoprocessorLoaded.set(false);
new MasterCoprocessorHost(masterServices, conf);
assertEquals("System coprocessors loading default was not honored", systemCoprocessorLoaded.get(), CoprocessorHost.DEFAULT_COPROCESSORS_ENABLED);
}
Aggregations