You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Ben West (Commented) (JIRA)" <ji...@apache.org> on 2012/03/19 19:57:44 UTC

[jira] [Commented] (HBASE-5600) Make Endpoint Coprocessors Available from Thrift

    [ https://issues.apache.org/jira/browse/HBASE-5600?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13232813#comment-13232813 ] 

Ben West commented on HBASE-5600:
---------------------------------

I'm not entirely sure how to accomplish this in full generality. The most obvious methods would involve sending java code through thrift, which is probably a no-go. However, here is one simple coprocessor which I have that it seems could be handled:

{code}
Batch.Call call = Batch.forMethod(IMyEndpoint.class, "getRow", rowKey.getBytes());
Map<byte[], byte[]> results = table.coprocessorExec(IMyEndpoint.class, null, null, call);
{code}

We could create a thrift method to take the name of the class, method, and an array of params and then call coprocessorExec. If this sounds reasonable, I can try to allocate some time for a patch.

Alternatively, we could just require that you write a client for your endpoints, and then thrift calls the client.
                
> Make Endpoint Coprocessors Available from Thrift
> ------------------------------------------------
>
>                 Key: HBASE-5600
>                 URL: https://issues.apache.org/jira/browse/HBASE-5600
>             Project: HBase
>          Issue Type: Improvement
>          Components: thrift
>            Reporter: Ben West
>            Priority: Minor
>              Labels: thrift
>
> Currently, the only way to access an endpoint coprocessor via thrift is to modify the schema and Thrift server for every coprocessor function. This is annoying. It should be possible to use your coprocessors without having to mangle HBase core code (since that's the point of coprocessors).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira