org.apache.hadoop.hbase.master
Class MasterCoprocessorHost

java.lang.Object
  extended by org.apache.hadoop.hbase.coprocessor.CoprocessorHost<org.apache.hadoop.hbase.master.MasterCoprocessorHost.MasterEnvironment>
      extended by org.apache.hadoop.hbase.master.MasterCoprocessorHost

@InterfaceAudience.Private
public class MasterCoprocessorHost
extends CoprocessorHost<org.apache.hadoop.hbase.master.MasterCoprocessorHost.MasterEnvironment>

Provides the coprocessor framework and environment for master oriented operations. HMaster interacts with the loaded coprocessors through this class.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.hadoop.hbase.coprocessor.CoprocessorHost
CoprocessorHost.Environment
 
Field Summary
 
Fields inherited from class org.apache.hadoop.hbase.coprocessor.CoprocessorHost
ABORT_ON_ERROR_KEY, abortable, conf, coprocessors, COPROCESSORS_ENABLED_CONF_KEY, DEFAULT_ABORT_ON_ERROR, DEFAULT_COPROCESSORS_ENABLED, DEFAULT_USER_COPROCESSORS_ENABLED, loadSequence, MASTER_COPROCESSOR_CONF_KEY, pathPrefix, REGION_COPROCESSOR_CONF_KEY, REGIONSERVER_COPROCESSOR_CONF_KEY, USER_COPROCESSORS_ENABLED_CONF_KEY, USER_REGION_COPROCESSOR_CONF_KEY, WAL_COPROCESSOR_CONF_KEY
 
Constructor Summary
MasterCoprocessorHost(MasterServices services, org.apache.hadoop.conf.Configuration conf)
           
 
Method Summary
 org.apache.hadoop.hbase.master.MasterCoprocessorHost.MasterEnvironment createEnvironment(Class<?> implClass, Coprocessor instance, int priority, int seq, org.apache.hadoop.conf.Configuration conf)
          Called when a new Coprocessor class is loaded
 void postAddColumn(TableName tableName, HColumnDescriptor column)
           
 void postAddColumnHandler(TableName tableName, HColumnDescriptor column)
           
 void postAssign(HRegionInfo regionInfo)
           
 void postBalance(List<RegionPlan> plans)
           
 void postBalanceSwitch(boolean oldValue, boolean newValue)
           
 void postCloneSnapshot(HBaseProtos.SnapshotDescription snapshot, HTableDescriptor hTableDescriptor)
           
 void postCreateNamespace(NamespaceDescriptor ns)
           
 void postCreateTable(HTableDescriptor htd, HRegionInfo[] regions)
           
 void postCreateTableHandler(HTableDescriptor htd, HRegionInfo[] regions)
           
 void postDeleteColumn(TableName tableName, byte[] c)
           
 void postDeleteColumnHandler(TableName tableName, byte[] c)
           
 void postDeleteNamespace(String namespaceName)
           
 void postDeleteSnapshot(HBaseProtos.SnapshotDescription snapshot)
           
 void postDeleteTable(TableName tableName)
           
 void postDeleteTableHandler(TableName tableName)
           
 void postDisableTable(TableName tableName)
           
 void postDisableTableHandler(TableName tableName)
           
 void postEnableTable(TableName tableName)
           
 void postEnableTableHandler(TableName tableName)
           
 void postGetTableDescriptors(List<HTableDescriptor> descriptors)
           
 void postModifyColumn(TableName tableName, HColumnDescriptor descriptor)
           
 void postModifyColumnHandler(TableName tableName, HColumnDescriptor descriptor)
           
 void postModifyNamespace(NamespaceDescriptor ns)
           
 void postModifyTable(TableName tableName, HTableDescriptor htd)
           
 void postModifyTableHandler(TableName tableName, HTableDescriptor htd)
           
 void postMove(HRegionInfo region, ServerName srcServer, ServerName destServer)
           
 void postRegionOffline(HRegionInfo regionInfo)
           
 void postRestoreSnapshot(HBaseProtos.SnapshotDescription snapshot, HTableDescriptor hTableDescriptor)
           
 void postSnapshot(HBaseProtos.SnapshotDescription snapshot, HTableDescriptor hTableDescriptor)
           
 void postStartMaster()
           
 void postTruncateTable(TableName tableName)
           
 void postTruncateTableHandler(TableName tableName)
           
 void postUnassign(HRegionInfo regionInfo, boolean force)
           
 boolean preAddColumn(TableName tableName, HColumnDescriptor column)
           
 boolean preAddColumnHandler(TableName tableName, HColumnDescriptor column)
           
 boolean preAssign(HRegionInfo regionInfo)
           
 boolean preBalance()
           
 boolean preBalanceSwitch(boolean b)
           
 void preCloneSnapshot(HBaseProtos.SnapshotDescription snapshot, HTableDescriptor hTableDescriptor)
           
 boolean preCreateNamespace(NamespaceDescriptor ns)
           
 void preCreateTable(HTableDescriptor htd, HRegionInfo[] regions)
           
 void preCreateTableHandler(HTableDescriptor htd, HRegionInfo[] regions)
           
 boolean preDeleteColumn(TableName tableName, byte[] c)
           
 boolean preDeleteColumnHandler(TableName tableName, byte[] c)
           
 boolean preDeleteNamespace(String namespaceName)
           
 void preDeleteSnapshot(HBaseProtos.SnapshotDescription snapshot)
           
 void preDeleteTable(TableName tableName)
           
 void preDeleteTableHandler(TableName tableName)
           
 void preDisableTable(TableName tableName)
           
 void preDisableTableHandler(TableName tableName)
           
 void preEnableTable(TableName tableName)
           
 void preEnableTableHandler(TableName tableName)
           
 boolean preGetTableDescriptors(List<TableName> tableNamesList, List<HTableDescriptor> descriptors)
           
 void preMasterInitialization()
           
 boolean preModifyColumn(TableName tableName, HColumnDescriptor descriptor)
           
 boolean preModifyColumnHandler(TableName tableName, HColumnDescriptor descriptor)
           
 boolean preModifyNamespace(NamespaceDescriptor ns)
           
 void preModifyTable(TableName tableName, HTableDescriptor htd)
           
 void preModifyTableHandler(TableName tableName, HTableDescriptor htd)
           
 boolean preMove(HRegionInfo region, ServerName srcServer, ServerName destServer)
           
 void preRegionOffline(HRegionInfo regionInfo)
           
 void preRestoreSnapshot(HBaseProtos.SnapshotDescription snapshot, HTableDescriptor hTableDescriptor)
           
 void preShutdown()
           
 void preSnapshot(HBaseProtos.SnapshotDescription snapshot, HTableDescriptor hTableDescriptor)
           
 void preStopMaster()
           
 void preTruncateTable(TableName tableName)
           
 void preTruncateTableHandler(TableName tableName)
           
 boolean preUnassign(HRegionInfo regionInfo, boolean force)
           
 
Methods inherited from class org.apache.hadoop.hbase.coprocessor.CoprocessorHost
abortServer, abortServer, findCoprocessor, findCoprocessorEnvironment, findCoprocessors, getCoprocessors, getLoadedCoprocessors, handleCoprocessorThrowable, load, load, loadInstance, loadSystemCoprocessors, shutdown
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MasterCoprocessorHost

public MasterCoprocessorHost(MasterServices services,
                             org.apache.hadoop.conf.Configuration conf)
Method Detail

createEnvironment

public org.apache.hadoop.hbase.master.MasterCoprocessorHost.MasterEnvironment createEnvironment(Class<?> implClass,
                                                                                                Coprocessor instance,
                                                                                                int priority,
                                                                                                int seq,
                                                                                                org.apache.hadoop.conf.Configuration conf)
Description copied from class: CoprocessorHost
Called when a new Coprocessor class is loaded

Specified by:
createEnvironment in class CoprocessorHost<org.apache.hadoop.hbase.master.MasterCoprocessorHost.MasterEnvironment>

preCreateNamespace

public boolean preCreateNamespace(NamespaceDescriptor ns)
                           throws IOException
Throws:
IOException

postCreateNamespace

public void postCreateNamespace(NamespaceDescriptor ns)
                         throws IOException
Throws:
IOException

preDeleteNamespace

public boolean preDeleteNamespace(String namespaceName)
                           throws IOException
Throws:
IOException

postDeleteNamespace

public void postDeleteNamespace(String namespaceName)
                         throws IOException
Throws:
IOException

preModifyNamespace

public boolean preModifyNamespace(NamespaceDescriptor ns)
                           throws IOException
Throws:
IOException

postModifyNamespace

public void postModifyNamespace(NamespaceDescriptor ns)
                         throws IOException
Throws:
IOException

preCreateTable

public void preCreateTable(HTableDescriptor htd,
                           HRegionInfo[] regions)
                    throws IOException
Throws:
IOException

postCreateTable

public void postCreateTable(HTableDescriptor htd,
                            HRegionInfo[] regions)
                     throws IOException
Throws:
IOException

preCreateTableHandler

public void preCreateTableHandler(HTableDescriptor htd,
                                  HRegionInfo[] regions)
                           throws IOException
Throws:
IOException

postCreateTableHandler

public void postCreateTableHandler(HTableDescriptor htd,
                                   HRegionInfo[] regions)
                            throws IOException
Throws:
IOException

preDeleteTable

public void preDeleteTable(TableName tableName)
                    throws IOException
Throws:
IOException

postDeleteTable

public void postDeleteTable(TableName tableName)
                     throws IOException
Throws:
IOException

preDeleteTableHandler

public void preDeleteTableHandler(TableName tableName)
                           throws IOException
Throws:
IOException

postDeleteTableHandler

public void postDeleteTableHandler(TableName tableName)
                            throws IOException
Throws:
IOException

preTruncateTable

public void preTruncateTable(TableName tableName)
                      throws IOException
Throws:
IOException

postTruncateTable

public void postTruncateTable(TableName tableName)
                       throws IOException
Throws:
IOException

preTruncateTableHandler

public void preTruncateTableHandler(TableName tableName)
                             throws IOException
Throws:
IOException

postTruncateTableHandler

public void postTruncateTableHandler(TableName tableName)
                              throws IOException
Throws:
IOException

preModifyTable

public void preModifyTable(TableName tableName,
                           HTableDescriptor htd)
                    throws IOException
Throws:
IOException

postModifyTable

public void postModifyTable(TableName tableName,
                            HTableDescriptor htd)
                     throws IOException
Throws:
IOException

preModifyTableHandler

public void preModifyTableHandler(TableName tableName,
                                  HTableDescriptor htd)
                           throws IOException
Throws:
IOException

postModifyTableHandler

public void postModifyTableHandler(TableName tableName,
                                   HTableDescriptor htd)
                            throws IOException
Throws:
IOException

preAddColumn

public boolean preAddColumn(TableName tableName,
                            HColumnDescriptor column)
                     throws IOException
Throws:
IOException

postAddColumn

public void postAddColumn(TableName tableName,
                          HColumnDescriptor column)
                   throws IOException
Throws:
IOException

preAddColumnHandler

public boolean preAddColumnHandler(TableName tableName,
                                   HColumnDescriptor column)
                            throws IOException
Throws:
IOException

postAddColumnHandler

public void postAddColumnHandler(TableName tableName,
                                 HColumnDescriptor column)
                          throws IOException
Throws:
IOException

preModifyColumn

public boolean preModifyColumn(TableName tableName,
                               HColumnDescriptor descriptor)
                        throws IOException
Throws:
IOException

postModifyColumn

public void postModifyColumn(TableName tableName,
                             HColumnDescriptor descriptor)
                      throws IOException
Throws:
IOException

preModifyColumnHandler

public boolean preModifyColumnHandler(TableName tableName,
                                      HColumnDescriptor descriptor)
                               throws IOException
Throws:
IOException

postModifyColumnHandler

public void postModifyColumnHandler(TableName tableName,
                                    HColumnDescriptor descriptor)
                             throws IOException
Throws:
IOException

preDeleteColumn

public boolean preDeleteColumn(TableName tableName,
                               byte[] c)
                        throws IOException
Throws:
IOException

postDeleteColumn

public void postDeleteColumn(TableName tableName,
                             byte[] c)
                      throws IOException
Throws:
IOException

preDeleteColumnHandler

public boolean preDeleteColumnHandler(TableName tableName,
                                      byte[] c)
                               throws IOException
Throws:
IOException

postDeleteColumnHandler

public void postDeleteColumnHandler(TableName tableName,
                                    byte[] c)
                             throws IOException
Throws:
IOException

preEnableTable

public void preEnableTable(TableName tableName)
                    throws IOException
Throws:
IOException

postEnableTable

public void postEnableTable(TableName tableName)
                     throws IOException
Throws:
IOException

preEnableTableHandler

public void preEnableTableHandler(TableName tableName)
                           throws IOException
Throws:
IOException

postEnableTableHandler

public void postEnableTableHandler(TableName tableName)
                            throws IOException
Throws:
IOException

preDisableTable

public void preDisableTable(TableName tableName)
                     throws IOException
Throws:
IOException

postDisableTable

public void postDisableTable(TableName tableName)
                      throws IOException
Throws:
IOException

preDisableTableHandler

public void preDisableTableHandler(TableName tableName)
                            throws IOException
Throws:
IOException

postDisableTableHandler

public void postDisableTableHandler(TableName tableName)
                             throws IOException
Throws:
IOException

preMove

public boolean preMove(HRegionInfo region,
                       ServerName srcServer,
                       ServerName destServer)
                throws IOException
Throws:
IOException

postMove

public void postMove(HRegionInfo region,
                     ServerName srcServer,
                     ServerName destServer)
              throws IOException
Throws:
IOException

preAssign

public boolean preAssign(HRegionInfo regionInfo)
                  throws IOException
Throws:
IOException

postAssign

public void postAssign(HRegionInfo regionInfo)
                throws IOException
Throws:
IOException

preUnassign

public boolean preUnassign(HRegionInfo regionInfo,
                           boolean force)
                    throws IOException
Throws:
IOException

postUnassign

public void postUnassign(HRegionInfo regionInfo,
                         boolean force)
                  throws IOException
Throws:
IOException

preRegionOffline

public void preRegionOffline(HRegionInfo regionInfo)
                      throws IOException
Throws:
IOException

postRegionOffline

public void postRegionOffline(HRegionInfo regionInfo)
                       throws IOException
Throws:
IOException

preBalance

public boolean preBalance()
                   throws IOException
Throws:
IOException

postBalance

public void postBalance(List<RegionPlan> plans)
                 throws IOException
Throws:
IOException

preBalanceSwitch

public boolean preBalanceSwitch(boolean b)
                         throws IOException
Throws:
IOException

postBalanceSwitch

public void postBalanceSwitch(boolean oldValue,
                              boolean newValue)
                       throws IOException
Throws:
IOException

preShutdown

public void preShutdown()
                 throws IOException
Throws:
IOException

preStopMaster

public void preStopMaster()
                   throws IOException
Throws:
IOException

preMasterInitialization

public void preMasterInitialization()
                             throws IOException
Throws:
IOException

postStartMaster

public void postStartMaster()
                     throws IOException
Throws:
IOException

preSnapshot

public void preSnapshot(HBaseProtos.SnapshotDescription snapshot,
                        HTableDescriptor hTableDescriptor)
                 throws IOException
Throws:
IOException

postSnapshot

public void postSnapshot(HBaseProtos.SnapshotDescription snapshot,
                         HTableDescriptor hTableDescriptor)
                  throws IOException
Throws:
IOException

preCloneSnapshot

public void preCloneSnapshot(HBaseProtos.SnapshotDescription snapshot,
                             HTableDescriptor hTableDescriptor)
                      throws IOException
Throws:
IOException

postCloneSnapshot

public void postCloneSnapshot(HBaseProtos.SnapshotDescription snapshot,
                              HTableDescriptor hTableDescriptor)
                       throws IOException
Throws:
IOException

preRestoreSnapshot

public void preRestoreSnapshot(HBaseProtos.SnapshotDescription snapshot,
                               HTableDescriptor hTableDescriptor)
                        throws IOException
Throws:
IOException

postRestoreSnapshot

public void postRestoreSnapshot(HBaseProtos.SnapshotDescription snapshot,
                                HTableDescriptor hTableDescriptor)
                         throws IOException
Throws:
IOException

preDeleteSnapshot

public void preDeleteSnapshot(HBaseProtos.SnapshotDescription snapshot)
                       throws IOException
Throws:
IOException

postDeleteSnapshot

public void postDeleteSnapshot(HBaseProtos.SnapshotDescription snapshot)
                        throws IOException
Throws:
IOException

preGetTableDescriptors

public boolean preGetTableDescriptors(List<TableName> tableNamesList,
                                      List<HTableDescriptor> descriptors)
                               throws IOException
Throws:
IOException

postGetTableDescriptors

public void postGetTableDescriptors(List<HTableDescriptor> descriptors)
                             throws IOException
Throws:
IOException


Copyright © 2015 The Apache Software Foundation. All rights reserved.