Abhishek Singh Chouhan commented on HBASE-18127:

Sorry for the delayed response on this [~stack] [~lhofhansl] [~anoop.hbase]. 
Got a bit busy. Putting up a patch that brings the interface back and marks the 
implementation private. Also have put the enum in the interface itself rather 
than top level HConstants.

bq. What is a 'hook'?
Was under the impression that the coprocessor methods that are implemented by 
various coprocessors are called hooks. The jira title also has similar 
terninology :) Let me know if i should use something else boss.

bq. Context is done for RowProcessor only. Should this notion be across CPs?
Have introduced this for batchMutate and related hooks as of now since this is 
the initial requirement. We can have context for other operations too, but 
thought that we can add those as and when required.

bq. This breaks CPs? Its a 2.0 hbase-only facility?
Main changes are on ObserverContext(addition of new getter and setter) and 
RowProcessor APIs both of which are limited private for cp and evolving so we 
can change in minor upgrade too by the look of it. Probably can go in 1.4+.

Thanks for having a look!!

> Enable state to be passed between the region observer coprocessor hook calls
> ----------------------------------------------------------------------------
>                 Key: HBASE-18127
>                 URL: https://issues.apache.org/jira/browse/HBASE-18127
>             Project: HBase
>          Issue Type: New Feature
>            Reporter: Lars Hofhansl
>            Assignee: Abhishek Singh Chouhan
>         Attachments: HBASE-18127.master.001.patch, 
> HBASE-18127.master.002.patch, HBASE-18127.master.002.patch
> Allow regionobserver to optionally skip postPut/postDelete when 
> postBatchMutate was called.
> Right now a RegionObserver can only statically implement one or the other. In 
> scenarios where we need to work sometimes on the single postPut and 
> postDelete hooks and sometimes on the batchMutate hooks, there is currently 
> no place to convey this information to the single hooks. I.e. the work has 
> been done in the batch, skip the single hooks.
> There are various solutions:
> 1. Allow some state to be passed _per operation_.
> 2. Remove the single hooks and always only call batch hooks (with a default 
> wrapper for the single hooks).
> 3. more?
> [~apurtell], what we had discussed a few days back.

This message was sent by Atlassian JIRA

Reply via email to