This is a remnant from initial plans to do single-RPC-per-RS batching of
coprocessor RPCs via the parameterized
HConnectionManager.HConnectionImplementation.processBatchCallback() method.
Currently we do a single RPC per region for HTable.coprocessorExec()
invocations.

processBatchCallback() takes a List<? extends Row>, hence the "implements"
for Exec.

I had originally planned on doing this enhancement (there was one hurdle in
scoping of some vars within ExecRPCInvoker as I recall), but obviously
haven't gotten around to it, so feel free to remove the Row implementation.
I don't think it's needed for the current
HConnectionManager.HConnectionImplementation.processExecs() method.

I don't really agree that this is a big issue of confusion though.  Exec is
part of the internal implementation and referenceRow has local javadoc.
Exec class javadoc also references HTable.coprocessorExec javadoc, which
goes to lengths to explain how the row key is used.  But, again, the Row
implementation isn't currently used, so it's just dead weight.  Feel free to
drop it.

--gh


On Wed, Apr 27, 2011 at 10:06 PM, Stack <[email protected]> wrote:

> I took a look.  Could not figure it out.  I think 'reference row'
> needs to be explained better (or implementation of Row Interface
> removed -- gives impression that CP is row scoped; I don't think that
> the case).
>
> St.Ack
>
> On Wed, Apr 27, 2011 at 9:08 PM, Himanshu Vashishtha
> <[email protected]> wrote:
> > Its not clear why org.apache.hadoop.hbase.client.coprocessor.Exec
> implements
> > Row interface. It seems the row attribute is not used as such apart from
> > passing it to server side as a part of Exec object. Is this intentional
> or I
> > am missing something.
> >
> > Though its comparatively older code now, but still would be good to know
> the
> > reason.
> >
> > Thanks,
> > Himanshu
> >
>

Reply via email to