-RE: connect to the region from coprocessor
Ramkrishna.S.Vasudevan 2012-10-10, 12:04
Here oldValue anyway will have the same rowkey right. So it should be in the same region but as older version.
> -----Original Message-----
> From: Jean-Marc Spaggiari [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, October 10, 2012 5:24 PM
> To: [EMAIL PROTECTED]
> Subject: Re: connect to the region from coprocessor
> But is it possible that the previous value for this row to be stored
> in another region?
> I mean, if cells are big, they might be on different regions /
> 2012/10/10, Anoop Sam John <[EMAIL PROTECTED]>:
> > Hi
> > To your prePut() method you are getting an ObserverContext
> > From this you can easily get a ref to the current region.
> > ctx.getEnvironment().getRegion()
> > Directly make calls to this region object. Creation of the HTable
> > and making a get() will be too much unwanted overhead.
> > -Anoop-
> > ________________________________________
> > From: Wei Tan [[EMAIL PROTECTED]]
> > Sent: Wednesday, October 10, 2012 2:05 AM
> > To: [EMAIL PROTECTED]
> > Subject: connect to the region from coprocessor
> > Hi,
> > In my preput coprocessor I would like to get the old value of the row
> > input. Now I am creating a HTable instance and using the get
> > function wise it works fine. Given the row is physically in the same
> > region as the cp, is there any lightweight approach doing that?
> > Thanks!
> > Best Regards,
> > Wei