@InterfaceAudience.LimitedPrivate(value="Coprocesssor") @InterfaceStability.Evolving public interface RowProcessor<S extends Message,T extends Message>
| Modifier and Type | Method and Description | 
|---|---|
List<UUID> | 
getClusterIds()  | 
String | 
getName()
Human readable name of the processor 
 | 
S | 
getRequestData()
This method should return any additional data that is needed on the
 server side to construct the RowProcessor. 
 | 
T | 
getResult()
Obtain the processing result. 
 | 
Collection<byte[]> | 
getRowsToLock()
Rows to lock while operation. 
 | 
void | 
initialize(S msg)
This method should initialize any field(s) of the RowProcessor with
 a parsing of the passed message bytes (used on the server side). 
 | 
void | 
postBatchMutate(HRegion region)
The hook to be executed after the process() and applying the Mutations to region. 
 | 
void | 
postProcess(HRegion region,
           WALEdit walEdit,
           boolean success)
The hook to be executed after process() and applying the Mutations to region. 
 | 
void | 
preBatchMutate(HRegion region,
              WALEdit walEdit)
The hook to be executed after the process() but before applying the Mutations to region. 
 | 
void | 
preProcess(HRegion region,
          WALEdit walEdit)
The hook to be executed before process(). 
 | 
void | 
process(long now,
       HRegion region,
       List<Mutation> mutations,
       WALEdit walEdit)
HRegion handles the locks and MVCC and invokes this method properly. 
 | 
boolean | 
readOnly()
Is this operation read only? If this is true, process() should not add
 any mutations or it throws IOException. 
 | 
Durability | 
useDurability()  | 
Collection<byte[]> getRowsToLock()
RowProcessor
 to avoid deadlock.T getResult()
boolean readOnly()
void process(long now,
             HRegion region,
             List<Mutation> mutations,
             WALEdit walEdit)
      throws IOException
IsolationLevel.READ_UNCOMMITTED for scan because
 we advance MVCC after releasing the locks for optimization purpose.now - the current system millisecondregion - the HRegionmutations - the output mutations to apply to memstorewalEdit - the output WAL edits to apply to write ahead logIOExceptionvoid preProcess(HRegion region, WALEdit walEdit) throws IOException
region - the HRegionwalEdit - the output WAL edits to apply to write ahead logIOExceptionvoid preBatchMutate(HRegion region, WALEdit walEdit) throws IOException
region - walEdit - the output WAL edits to apply to write ahead logIOExceptionvoid postBatchMutate(HRegion region) throws IOException
postProcess(HRegion, WALEdit, boolean) is this hook will
 be executed before the mvcc transaction completion.region - IOExceptionvoid postProcess(HRegion region, WALEdit walEdit, boolean success) throws IOException
region - the HRegionwalEdit - the output WAL edits to apply to write ahead logsuccess - true if batch operation is successful otherwise false.IOExceptionString getName()
S getRequestData() throws IOException
initialize(Message msg) method. If there is no RowProcessor
 specific data then null should be returned.IOExceptionvoid initialize(S msg) throws IOException
msg - IOExceptionDurability useDurability()
Durability to use