Class ConstraintProcessor
java.lang.Object
org.apache.hadoop.hbase.constraint.ConstraintProcessor
- All Implemented Interfaces:
Coprocessor,RegionCoprocessor,RegionObserver
@Private
public class ConstraintProcessor
extends Object
implements RegionCoprocessor, RegionObserver
Processes multiple
Constraints on a given table.
This is an ease of use mechanism - all the functionality here could be implemented on any given system by a coprocessor.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.hadoop.hbase.Coprocessor
Coprocessor.StateNested classes/interfaces inherited from interface org.apache.hadoop.hbase.coprocessor.RegionObserver
RegionObserver.MutationType -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ClassLoaderprivate List<? extends Constraint>private static final org.slf4j.LoggerFields inherited from interface org.apache.hadoop.hbase.Coprocessor
PRIORITY_HIGHEST, PRIORITY_LOWEST, PRIORITY_SYSTEM, PRIORITY_USER, VERSION -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidprePut(ObserverContext<RegionCoprocessorEnvironment> e, Put put, WALEdit edit, Durability durability) Called before the client stores a value.voidstart(CoprocessorEnvironment environment) Called by theCoprocessorEnvironmentduring it's own startup to initialize the coprocessor.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.hadoop.hbase.Coprocessor
getServices, stopMethods inherited from interface org.apache.hadoop.hbase.coprocessor.RegionCoprocessor
getBulkLoadObserver, getEndpointObserverMethods inherited from interface org.apache.hadoop.hbase.coprocessor.RegionObserver
postAppend, postAppend, postAppendBeforeWAL, postBatchMutate, postBatchMutateIndispensably, postBulkLoadHFile, postCheckAndDelete, postCheckAndDelete, postCheckAndMutate, postCheckAndPut, postCheckAndPut, postClose, postCloseRegionOperation, postCommitStoreFile, postCompact, postCompactSelection, postDelete, postDelete, postExists, postFlush, postFlush, postGetOp, postIncrement, postIncrement, postIncrementBeforeWAL, postInstantiateDeleteTracker, postMemStoreCompaction, postMutationBeforeWAL, postOpen, postPut, postPut, postReplayWALs, postScannerClose, postScannerFilterRow, postScannerNext, postScannerOpen, postStartRegionOperation, postStoreFileReaderOpen, postWALRestore, preAppend, preAppend, preAppendAfterRowLock, preBatchMutate, preBulkLoadHFile, preCheckAndDelete, preCheckAndDelete, preCheckAndDeleteAfterRowLock, preCheckAndDeleteAfterRowLock, preCheckAndMutate, preCheckAndMutateAfterRowLock, preCheckAndPut, preCheckAndPut, preCheckAndPutAfterRowLock, preCheckAndPutAfterRowLock, preClose, preCommitStoreFile, preCompact, preCompactScannerOpen, preCompactSelection, preDelete, preDelete, preExists, preFlush, preFlush, preFlushScannerOpen, preGetOp, preIncrement, preIncrement, preIncrementAfterRowLock, preMemStoreCompaction, preMemStoreCompactionCompact, preMemStoreCompactionCompactScannerOpen, preOpen, prePrepareTimeStampForDeleteVersion, prePut, preReplayWALs, preScannerClose, preScannerNext, preScannerOpen, preStoreFileReaderOpen, preStoreScannerOpen, preWALAppend, preWALRestore
-
Field Details
-
LOG
-
classloader
-
constraints
-
-
Constructor Details
-
ConstraintProcessor
public ConstraintProcessor()Create the constraint processor.Stores the current classloader.
-
-
Method Details
-
getRegionObserver
- Specified by:
getRegionObserverin interfaceRegionCoprocessor
-
start
Description copied from interface:CoprocessorCalled by theCoprocessorEnvironmentduring it's own startup to initialize the coprocessor.- Specified by:
startin interfaceCoprocessor
-
prePut
public void prePut(ObserverContext<RegionCoprocessorEnvironment> e, Put put, WALEdit edit, Durability durability) throws IOException Description copied from interface:RegionObserverCalled before the client stores a value.Call CoprocessorEnvironment#bypass to skip default actions. If 'bypass' is set, we skip out on calling any subsequent chained coprocessors.
Note: Do not retain references to any Cells in 'put' beyond the life of this invocation. If need a Cell reference for later use, copy the cell and use that.
- Specified by:
prePutin interfaceRegionObserver- Parameters:
e- the environment provided by the region serverput- The Put objectedit- The WALEdit object that will be written to the waldurability- Persistence guarantee for this Put- Throws:
IOException
-