> So, it looks like RegionCoprocessorEnvironment.getRegion() has been
removed?

No, the signature has changed, basically s/HRegion/Region/. HRegion is an
internal, low level implementation type. Has always been. We have replaced
it with Region, an interface that contains a subset of HRegion we feel we
can support for coprocessor source and binary compatibility longer term.
This work was done on HBASE-12972 if you're curious to know more about it.

> I guess I deploy a new coproc that uses whatever the new method is, and
then in my client, detect at runtime which HBase version I'm talking to and
use that to determine which coprocessor to hit?

Coprocessors are server side extensions. These API changes will require you
to modify the code you plan to deploy on the server. I don't think any
client side changes are needed. Unless your coprocessor implements an
Endpoint and _you_ are changing your RPC message formats, a 1.0.x client
shouldn't care whether it is talking to a 1.0.x server or a 1.1.x server,
running your coprocessor or not.



On Wed, May 13, 2015 at 3:00 PM, James Estes <james.es...@gmail.com> wrote:

> I saw the vote thread for RC2, so tried to build my project against it.
>
> My build fails when I depend on 1.1.0. I created a bare bones project
> to show the issue I'm running into:
> https://github.com/housejester/hbase-deps-test
>
> To be clear, it works in 1.0.0 (and I did add the repository).
>
> Further, we have a coprocessor and when I stand up a 1.1.0 HBase and
> call my endpoint, I get:
>
> ! Caused by: java.lang.NoSuchMethodError:
>
> org.apache.hadoop.hbase.coprocessor.RegionCoprocessorEnvironment.getRegion()Lorg/apache/hadoop/hbase/regionserver/HRegion;
>
> The same coprocessor works under 1.0.0.
>
> So, it looks like RegionCoprocessorEnvironment.getRegion() has been
> removed?
>
> The Audience annotation is:
> @InterfaceAudience.LimitedPrivate(HBaseInterfaceAudience.COPROC)
> @InterfaceStability.Evolving
>
> Since it is Evolving it is allowed to change in a breaking way. I'm
> trying to think about how I migrate. I guess I deploy a new coproc
> that uses whatever the new method is, and then in my client, detect at
> runtime which HBase version I'm talking to and use that to determine
> which coprocessor to hit?
>
> Thanks,
> James
>



-- 
Best regards,

   - Andy

Problems worthy of attack prove their worth by hitting back. - Piet Hein
(via Tom White)

Reply via email to