[
https://issues.apache.org/jira/browse/HBASE-2038?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12934344#action_12934344
]
Andrew Purtell commented on HBASE-2038:
---------------------------------------
Alex,
bq. Is it in general a good idea to take this initiave (transform IHBase
implementation to CP-based one) by me?
Well I for one definitely think this is a good idea.
bq. I believe it's a good time for this effort and hope that CP-based
implementation of region-level indexing will confirm that CP API is complete
and has all one might need (for now).
As do I. However there are additions and improvements to the CP API coming, see
HBASE-3256 and HBASE-3257. The latter especially may be relevant.
bq. I assume that one instance is created and "assigned" to a region and that
CP implementation should be thread-safe (e.g. multiple scanners can be handled
at the same time for the regions).
Correct.
bq. I believe that CoprocessorEnvironment's get/put/remove methods are used to
store intermediate data (aka attributes) between method calls (if we really
need it).
Correct, but see next answer below.
bq. Is CoprocessorEnvironment instance is created one-per-region?
No. This is created once per coprocessor. Each coprocessor has its own
environment, which can be used to keep state between multiple threads of a
coprocessor attached to one region, but not between multiple coprocessors.
CoprocessorHost is the object that is created once per region.
bq. I can store some scan-related data using scanId passed to the scan-related
callbacks (is it safe?)
This should be safe.
I don't understand the current IHBase implementation enough to answer your
question #2.
bq. This refactored code somehow correlates with BaseRegionObserverCoprocessor
API (at least in my head)
I think that is a great start.
> Coprocessors: Region level indexing
> -----------------------------------
>
> Key: HBASE-2038
> URL: https://issues.apache.org/jira/browse/HBASE-2038
> Project: HBase
> Issue Type: Sub-task
> Reporter: Andrew Purtell
> Priority: Minor
>
> HBASE-2037 is a good candidate to be done as coprocessor. It also serve as a
> good goalpost for coprocessor environment design -- there should be enough of
> it so region level indexing can be reimplemented as a coprocessor without any
> loss of functionality.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.