|
|
-
Co-Processor in scanning the HBase's Table
Farrokh Shahriari 2013-02-17, 18:51
Hi there I wanna use a custom code after scanning a large table and prefer to run the code after scanning each region.I know that I should use co-processor,but don't know which of Observer,Endpoint or both of them I should use ? Is there any simple example of them ?
Tnx
-
Re: Co-Processor in scanning the HBase's Table
Amit Sela 2013-02-17, 19:47
You can use a postScan() region observer as a trigger to run your code or use endpoint that you (your code) will have to call after the scan. Try this link https://blogs.apache.org/hbase/entry/coprocessor_introductionGood luck. On Feb 17, 2013 8:51 PM, "Farrokh Shahriari" <[EMAIL PROTECTED]> wrote: > Hi there > I wanna use a custom code after scanning a large table and prefer to run > the code after scanning each region.I know that I should use > co-processor,but don't know which of Observer,Endpoint or both of them I > should use ? Is there any simple example of them ? > > Tnx >
-
RE: Co-Processor in scanning the HBase's Table
Anoop Sam John 2013-02-18, 04:15
>I wanna use a custom code after scanning a large table and prefer to run the code after scanning each region
Exactly at what point you want to run your custom code? We have hooks at points like opening a scanner at a region, closing scanner at a region, calling next (pre/post) etc
-Anoop- ________________________________________ From: Farrokh Shahriari [[EMAIL PROTECTED]] Sent: Monday, February 18, 2013 12:21 AM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Co-Processor in scanning the HBase's Table
Hi there I wanna use a custom code after scanning a large table and prefer to run the code after scanning each region.I know that I should use co-processor,but don't know which of Observer,Endpoint or both of them I should use ? Is there any simple example of them ?
Tnx
-
Re: Co-Processor in scanning the HBase's Table
Farrokh Shahriari 2013-02-18, 04:57
Thanks you Amit,I will check that. @Anoop: I wanna run that just after scanning a region or after scanning the regions that to belong to one regionserver.
On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John <[EMAIL PROTECTED]> wrote:
> >I wanna use a custom code after scanning a large table and prefer to run > the code after scanning each region > > Exactly at what point you want to run your custom code? We have hooks at > points like opening a scanner at a region, closing scanner at a region, > calling next (pre/post) etc > > -Anoop- > ________________________________________ > From: Farrokh Shahriari [[EMAIL PROTECTED]] > Sent: Monday, February 18, 2013 12:21 AM > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > Subject: Co-Processor in scanning the HBase's Table > > Hi there > I wanna use a custom code after scanning a large table and prefer to run > the code after scanning each region.I know that I should use > co-processor,but don't know which of Observer,Endpoint or both of them I > should use ? Is there any simple example of them ? > > Tnx >
-
RE: Co-Processor in scanning the HBase's Table
Anoop Sam John 2013-02-18, 05:23
We dont have any hook like postScan().. In ur case you can try with postScannerClose().. This will be called once per region. When the scan on that region is over the scanner opened on that region will get closed and at that time this hook will get executed.
-Anoop- ________________________________________ From: Farrokh Shahriari [[EMAIL PROTECTED]] Sent: Monday, February 18, 2013 10:27 AM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: Co-Processor in scanning the HBase's Table
Thanks you Amit,I will check that. @Anoop: I wanna run that just after scanning a region or after scanning the regions that to belong to one regionserver.
On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John <[EMAIL PROTECTED]> wrote:
> >I wanna use a custom code after scanning a large table and prefer to run > the code after scanning each region > > Exactly at what point you want to run your custom code? We have hooks at > points like opening a scanner at a region, closing scanner at a region, > calling next (pre/post) etc > > -Anoop- > ________________________________________ > From: Farrokh Shahriari [[EMAIL PROTECTED]] > Sent: Monday, February 18, 2013 12:21 AM > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > Subject: Co-Processor in scanning the HBase's Table > > Hi there > I wanna use a custom code after scanning a large table and prefer to run > the code after scanning each region.I know that I should use > co-processor,but don't know which of Observer,Endpoint or both of them I > should use ? Is there any simple example of them ? > > Tnx >
-
Re: Co-Processor in scanning the HBase's Table
Amit Sela 2013-02-18, 08:30
Yes... that was emailing half asleep... :)
On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED]> wrote:
> We dont have any hook like postScan().. In ur case you can try with > postScannerClose().. This will be called once per region. When the scan on > that region is over the scanner opened on that region will get closed and > at that time this hook will get executed. > > -Anoop- > ________________________________________ > From: Farrokh Shahriari [[EMAIL PROTECTED]] > Sent: Monday, February 18, 2013 10:27 AM > To: [EMAIL PROTECTED] > Cc: [EMAIL PROTECTED] > Subject: Re: Co-Processor in scanning the HBase's Table > > Thanks you Amit,I will check that. > @Anoop: I wanna run that just after scanning a region or after scanning the > regions that to belong to one regionserver. > > On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John <[EMAIL PROTECTED]> > wrote: > > > >I wanna use a custom code after scanning a large table and prefer to run > > the code after scanning each region > > > > Exactly at what point you want to run your custom code? We have hooks at > > points like opening a scanner at a region, closing scanner at a region, > > calling next (pre/post) etc > > > > -Anoop- > > ________________________________________ > > From: Farrokh Shahriari [[EMAIL PROTECTED]] > > Sent: Monday, February 18, 2013 12:21 AM > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > > Subject: Co-Processor in scanning the HBase's Table > > > > Hi there > > I wanna use a custom code after scanning a large table and prefer to run > > the code after scanning each region.I know that I should use > > co-processor,but don't know which of Observer,Endpoint or both of them I > > should use ? Is there any simple example of them ? > > > > Tnx > > >
-
Re: Co-Processor in scanning the HBase's Table
Farrokh Shahriari 2013-02-19, 17:33
Thanks you guys
On Mon, Feb 18, 2013 at 12:00 PM, Amit Sela <[EMAIL PROTECTED]> wrote:
> Yes... that was emailing half asleep... :) > > On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED]> > wrote: > > > We dont have any hook like postScan().. In ur case you can try with > > postScannerClose().. This will be called once per region. When the scan > on > > that region is over the scanner opened on that region will get closed and > > at that time this hook will get executed. > > > > -Anoop- > > ________________________________________ > > From: Farrokh Shahriari [[EMAIL PROTECTED]] > > Sent: Monday, February 18, 2013 10:27 AM > > To: [EMAIL PROTECTED] > > Cc: [EMAIL PROTECTED] > > Subject: Re: Co-Processor in scanning the HBase's Table > > > > Thanks you Amit,I will check that. > > @Anoop: I wanna run that just after scanning a region or after scanning > the > > regions that to belong to one regionserver. > > > > On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John <[EMAIL PROTECTED]> > > wrote: > > > > > >I wanna use a custom code after scanning a large table and prefer to > run > > > the code after scanning each region > > > > > > Exactly at what point you want to run your custom code? We have hooks > at > > > points like opening a scanner at a region, closing scanner at a region, > > > calling next (pre/post) etc > > > > > > -Anoop- > > > ________________________________________ > > > From: Farrokh Shahriari [[EMAIL PROTECTED]] > > > Sent: Monday, February 18, 2013 12:21 AM > > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > > > Subject: Co-Processor in scanning the HBase's Table > > > > > > Hi there > > > I wanna use a custom code after scanning a large table and prefer to > run > > > the code after scanning each region.I know that I should use > > > co-processor,but don't know which of Observer,Endpoint or both of them > I > > > should use ? Is there any simple example of them ? > > > > > > Tnx > > > > > >
-
Re: Co-Processor in scanning the HBase's Table
Farrokh Shahriari 2013-02-21, 13:44
Hello again, I've used PostScannerClose Regionobserver as the hbase book (Definitive Guide) says,but it doesn't seem worked.And I noticed that the PostScannerClose doesn't return any value like result. In fact,I just wanna doing a simple job as described below: Up to now,I've used a scanner to filter the columnFamily,then on the client side ( means at the result loop), filtered some other things,now I want to do that after scanning each region to reduce the amount of return results to client.
Please help me,I need it asap.
Farrokh
On Tue, Feb 19, 2013 at 9:03 PM, Farrokh Shahriari < [EMAIL PROTECTED]> wrote:
> Thanks you guys > > > On Mon, Feb 18, 2013 at 12:00 PM, Amit Sela <[EMAIL PROTECTED]> wrote: > >> Yes... that was emailing half asleep... :) >> >> On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED]> >> wrote: >> >> > We dont have any hook like postScan().. In ur case you can try with >> > postScannerClose().. This will be called once per region. When the >> scan on >> > that region is over the scanner opened on that region will get closed >> and >> > at that time this hook will get executed. >> > >> > -Anoop- >> > ________________________________________ >> > From: Farrokh Shahriari [[EMAIL PROTECTED]] >> > Sent: Monday, February 18, 2013 10:27 AM >> > To: [EMAIL PROTECTED] >> > Cc: [EMAIL PROTECTED] >> > Subject: Re: Co-Processor in scanning the HBase's Table >> > >> > Thanks you Amit,I will check that. >> > @Anoop: I wanna run that just after scanning a region or after scanning >> the >> > regions that to belong to one regionserver. >> > >> > On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John <[EMAIL PROTECTED]> >> > wrote: >> > >> > > >I wanna use a custom code after scanning a large table and prefer to >> run >> > > the code after scanning each region >> > > >> > > Exactly at what point you want to run your custom code? We have >> hooks at >> > > points like opening a scanner at a region, closing scanner at a >> region, >> > > calling next (pre/post) etc >> > > >> > > -Anoop- >> > > ________________________________________ >> > > From: Farrokh Shahriari [[EMAIL PROTECTED]] >> > > Sent: Monday, February 18, 2013 12:21 AM >> > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] >> > > Subject: Co-Processor in scanning the HBase's Table >> > > >> > > Hi there >> > > I wanna use a custom code after scanning a large table and prefer to >> run >> > > the code after scanning each region.I know that I should use >> > > co-processor,but don't know which of Observer,Endpoint or both of >> them I >> > > should use ? Is there any simple example of them ? >> > > >> > > Tnx >> > > >> > >> > >
-
Re: Co-Processor in scanning the HBase's Table
Anoop John 2013-02-21, 15:52
What is this filtering at client side doing exactly? postScannerClose() wont deal with any scanned data. This hook will be called later.. You should be using hooks with scanner's next calls. Mind telling the exact thing you are doing now at client side. Then we might be able to suggest some thing.
-Anoop-
On Thu, Feb 21, 2013 at 7:14 PM, Farrokh Shahriari < [EMAIL PROTECTED]> wrote:
> Hello again, > I've used PostScannerClose Regionobserver as the hbase book (Definitive > Guide) says,but it doesn't seem worked.And I noticed that the > PostScannerClose doesn't return any value like result. > In fact,I just wanna doing a simple job as described below: > Up to now,I've used a scanner to filter the columnFamily,then on the client > side ( means at the result loop), filtered some other things,now I want to > do that after scanning each region to reduce the amount of return results > to client. > > Please help me,I need it asap. > > Farrokh > > On Tue, Feb 19, 2013 at 9:03 PM, Farrokh Shahriari < > [EMAIL PROTECTED]> wrote: > > > Thanks you guys > > > > > > On Mon, Feb 18, 2013 at 12:00 PM, Amit Sela <[EMAIL PROTECTED]> wrote: > > > >> Yes... that was emailing half asleep... :) > >> > >> On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED]> > >> wrote: > >> > >> > We dont have any hook like postScan().. In ur case you can try with > >> > postScannerClose().. This will be called once per region. When the > >> scan on > >> > that region is over the scanner opened on that region will get closed > >> and > >> > at that time this hook will get executed. > >> > > >> > -Anoop- > >> > ________________________________________ > >> > From: Farrokh Shahriari [[EMAIL PROTECTED]] > >> > Sent: Monday, February 18, 2013 10:27 AM > >> > To: [EMAIL PROTECTED] > >> > Cc: [EMAIL PROTECTED] > >> > Subject: Re: Co-Processor in scanning the HBase's Table > >> > > >> > Thanks you Amit,I will check that. > >> > @Anoop: I wanna run that just after scanning a region or after > scanning > >> the > >> > regions that to belong to one regionserver. > >> > > >> > On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John <[EMAIL PROTECTED]> > >> > wrote: > >> > > >> > > >I wanna use a custom code after scanning a large table and prefer > to > >> run > >> > > the code after scanning each region > >> > > > >> > > Exactly at what point you want to run your custom code? We have > >> hooks at > >> > > points like opening a scanner at a region, closing scanner at a > >> region, > >> > > calling next (pre/post) etc > >> > > > >> > > -Anoop- > >> > > ________________________________________ > >> > > From: Farrokh Shahriari [[EMAIL PROTECTED]] > >> > > Sent: Monday, February 18, 2013 12:21 AM > >> > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > >> > > Subject: Co-Processor in scanning the HBase's Table > >> > > > >> > > Hi there > >> > > I wanna use a custom code after scanning a large table and prefer to > >> run > >> > > the code after scanning each region.I know that I should use > >> > > co-processor,but don't know which of Observer,Endpoint or both of > >> them I > >> > > should use ? Is there any simple example of them ? > >> > > > >> > > Tnx > >> > > > >> > > >> > > > > >
-
Re: Co-Processor in scanning the HBase's Table
Amit Sela 2013-02-21, 17:28
I think that if your intention is to do some kind of scan filtering on the server side then maybe an EndPoint coprocessor would be more fitting. You can iterate over the InternalScanner and return a Map<> with your filtered values. You can also check this link: http://hbase-coprocessor-experiments.blogspot.co.il/2011/05/extending.htmlGood Luck! On Thu, Feb 21, 2013 at 5:52 PM, Anoop John <[EMAIL PROTECTED]> wrote: > What is this filtering at client side doing exactly? > postScannerClose() wont deal with any scanned data. This hook will be > called later.. You should be using hooks with scanner's next calls. Mind > telling the exact thing you are doing now at client side. Then we might be > able to suggest some thing. > > -Anoop- > > On Thu, Feb 21, 2013 at 7:14 PM, Farrokh Shahriari < > [EMAIL PROTECTED]> wrote: > > > Hello again, > > I've used PostScannerClose Regionobserver as the hbase book (Definitive > > Guide) says,but it doesn't seem worked.And I noticed that the > > PostScannerClose doesn't return any value like result. > > In fact,I just wanna doing a simple job as described below: > > Up to now,I've used a scanner to filter the columnFamily,then on the > client > > side ( means at the result loop), filtered some other things,now I want > to > > do that after scanning each region to reduce the amount of return results > > to client. > > > > Please help me,I need it asap. > > > > Farrokh > > > > On Tue, Feb 19, 2013 at 9:03 PM, Farrokh Shahriari < > > [EMAIL PROTECTED]> wrote: > > > > > Thanks you guys > > > > > > > > > On Mon, Feb 18, 2013 at 12:00 PM, Amit Sela <[EMAIL PROTECTED]> > wrote: > > > > > >> Yes... that was emailing half asleep... :) > > >> > > >> On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED]> > > >> wrote: > > >> > > >> > We dont have any hook like postScan().. In ur case you can try with > > >> > postScannerClose().. This will be called once per region. When the > > >> scan on > > >> > that region is over the scanner opened on that region will get > closed > > >> and > > >> > at that time this hook will get executed. > > >> > > > >> > -Anoop- > > >> > ________________________________________ > > >> > From: Farrokh Shahriari [[EMAIL PROTECTED]] > > >> > Sent: Monday, February 18, 2013 10:27 AM > > >> > To: [EMAIL PROTECTED] > > >> > Cc: [EMAIL PROTECTED] > > >> > Subject: Re: Co-Processor in scanning the HBase's Table > > >> > > > >> > Thanks you Amit,I will check that. > > >> > @Anoop: I wanna run that just after scanning a region or after > > scanning > > >> the > > >> > regions that to belong to one regionserver. > > >> > > > >> > On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John <[EMAIL PROTECTED] > > > > >> > wrote: > > >> > > > >> > > >I wanna use a custom code after scanning a large table and prefer > > to > > >> run > > >> > > the code after scanning each region > > >> > > > > >> > > Exactly at what point you want to run your custom code? We have > > >> hooks at > > >> > > points like opening a scanner at a region, closing scanner at a > > >> region, > > >> > > calling next (pre/post) etc > > >> > > > > >> > > -Anoop- > > >> > > ________________________________________ > > >> > > From: Farrokh Shahriari [[EMAIL PROTECTED]] > > >> > > Sent: Monday, February 18, 2013 12:21 AM > > >> > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > > >> > > Subject: Co-Processor in scanning the HBase's Table > > >> > > > > >> > > Hi there > > >> > > I wanna use a custom code after scanning a large table and prefer > to > > >> run > > >> > > the code after scanning each region.I know that I should use > > >> > > co-processor,but don't know which of Observer,Endpoint or both of > > >> them I > > >> > > should use ? Is there any simple example of them ? > > >> > > > > >> > > Tnx > > >> > > > > >> > > > >> > > > > > > > > >
-
Re: Co-Processor in scanning the HBase's Table
Farrokh Shahriari 2013-02-22, 13:55
@Anoop : Here is my situation: I have 2 columnFamilies(cf1,cf2),5-50 qualifiers(they are variable),first I should check the value of qualifiers in cf2,then if they equal to some values I'm going to get the values of cf1 by that rowkey. @Amita: thank you.I will check that too. Farrokh On Thu, Feb 21, 2013 at 8:58 PM, Amit Sela <[EMAIL PROTECTED]> wrote: > I think that if your intention is to do some kind of scan filtering on the > server side then maybe an EndPoint coprocessor would be more fitting. > You can iterate over the InternalScanner and return a Map<> with your > filtered values. > > You can also check this link: > http://hbase-coprocessor-experiments.blogspot.co.il/2011/05/extending.html> > Good Luck! > > On Thu, Feb 21, 2013 at 5:52 PM, Anoop John <[EMAIL PROTECTED]> wrote: > > > What is this filtering at client side doing exactly? > > postScannerClose() wont deal with any scanned data. This hook will be > > called later.. You should be using hooks with scanner's next calls. > Mind > > telling the exact thing you are doing now at client side. Then we might > be > > able to suggest some thing. > > > > -Anoop- > > > > On Thu, Feb 21, 2013 at 7:14 PM, Farrokh Shahriari < > > [EMAIL PROTECTED]> wrote: > > > > > Hello again, > > > I've used PostScannerClose Regionobserver as the hbase book (Definitive > > > Guide) says,but it doesn't seem worked.And I noticed that the > > > PostScannerClose doesn't return any value like result. > > > In fact,I just wanna doing a simple job as described below: > > > Up to now,I've used a scanner to filter the columnFamily,then on the > > client > > > side ( means at the result loop), filtered some other things,now I want > > to > > > do that after scanning each region to reduce the amount of return > results > > > to client. > > > > > > Please help me,I need it asap. > > > > > > Farrokh > > > > > > On Tue, Feb 19, 2013 at 9:03 PM, Farrokh Shahriari < > > > [EMAIL PROTECTED]> wrote: > > > > > > > Thanks you guys > > > > > > > > > > > > On Mon, Feb 18, 2013 at 12:00 PM, Amit Sela <[EMAIL PROTECTED]> > > wrote: > > > > > > > >> Yes... that was emailing half asleep... :) > > > >> > > > >> On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED] > > > > > >> wrote: > > > >> > > > >> > We dont have any hook like postScan().. In ur case you can try > with > > > >> > postScannerClose().. This will be called once per region. When > the > > > >> scan on > > > >> > that region is over the scanner opened on that region will get > > closed > > > >> and > > > >> > at that time this hook will get executed. > > > >> > > > > >> > -Anoop- > > > >> > ________________________________________ > > > >> > From: Farrokh Shahriari [[EMAIL PROTECTED]] > > > >> > Sent: Monday, February 18, 2013 10:27 AM > > > >> > To: [EMAIL PROTECTED] > > > >> > Cc: [EMAIL PROTECTED] > > > >> > Subject: Re: Co-Processor in scanning the HBase's Table > > > >> > > > > >> > Thanks you Amit,I will check that. > > > >> > @Anoop: I wanna run that just after scanning a region or after > > > scanning > > > >> the > > > >> > regions that to belong to one regionserver. > > > >> > > > > >> > On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John < > [EMAIL PROTECTED] > > > > > > >> > wrote: > > > >> > > > > >> > > >I wanna use a custom code after scanning a large table and > prefer > > > to > > > >> run > > > >> > > the code after scanning each region > > > >> > > > > > >> > > Exactly at what point you want to run your custom code? We have > > > >> hooks at > > > >> > > points like opening a scanner at a region, closing scanner at a > > > >> region, > > > >> > > calling next (pre/post) etc > > > >> > > > > > >> > > -Anoop- > > > >> > > ________________________________________ > > > >> > > From: Farrokh Shahriari [[EMAIL PROTECTED]] > > > >> > > Sent: Monday, February 18, 2013 12:21 AM > > > >> > > To: [EMAIL PROTECTED]; [EMAIL PROTECTED] > > > >> > > Subject: Co-Processor in scanning the HBase's Table
-
Re: Co-Processor in scanning the HBase's Table
Ted 2013-02-22, 14:16
Hbase-5416 should help your use case. Cf2 would be the essential column family. This feature is available in 0.94.5 Cheers On Feb 22, 2013, at 5:55 AM, Farrokh Shahriari <[EMAIL PROTECTED]> wrote: > @Anoop : Here is my situation: I have 2 columnFamilies(cf1,cf2),5-50 > qualifiers(they are variable),first I should check the value of qualifiers > in cf2,then if they equal to some values I'm going to get the values of cf1 > by that rowkey. > > @Amita: thank you.I will check that too. > > Farrokh > On Thu, Feb 21, 2013 at 8:58 PM, Amit Sela <[EMAIL PROTECTED]> wrote: > >> I think that if your intention is to do some kind of scan filtering on the >> server side then maybe an EndPoint coprocessor would be more fitting. >> You can iterate over the InternalScanner and return a Map<> with your >> filtered values. >> >> You can also check this link: >> http://hbase-coprocessor-experiments.blogspot.co.il/2011/05/extending.html>> >> Good Luck! >> >> On Thu, Feb 21, 2013 at 5:52 PM, Anoop John <[EMAIL PROTECTED]> wrote: >> >>> What is this filtering at client side doing exactly? >>> postScannerClose() wont deal with any scanned data. This hook will be >>> called later.. You should be using hooks with scanner's next calls. >> Mind >>> telling the exact thing you are doing now at client side. Then we might >> be >>> able to suggest some thing. >>> >>> -Anoop- >>> >>> On Thu, Feb 21, 2013 at 7:14 PM, Farrokh Shahriari < >>> [EMAIL PROTECTED]> wrote: >>> >>>> Hello again, >>>> I've used PostScannerClose Regionobserver as the hbase book (Definitive >>>> Guide) says,but it doesn't seem worked.And I noticed that the >>>> PostScannerClose doesn't return any value like result. >>>> In fact,I just wanna doing a simple job as described below: >>>> Up to now,I've used a scanner to filter the columnFamily,then on the >>> client >>>> side ( means at the result loop), filtered some other things,now I want >>> to >>>> do that after scanning each region to reduce the amount of return >> results >>>> to client. >>>> >>>> Please help me,I need it asap. >>>> >>>> Farrokh >>>> >>>> On Tue, Feb 19, 2013 at 9:03 PM, Farrokh Shahriari < >>>> [EMAIL PROTECTED]> wrote: >>>> >>>>> Thanks you guys >>>>> >>>>> >>>>> On Mon, Feb 18, 2013 at 12:00 PM, Amit Sela <[EMAIL PROTECTED]> >>> wrote: >>>>> >>>>>> Yes... that was emailing half asleep... :) >>>>>> >>>>>> On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED] >>> >>>>>> wrote: >>>>>> >>>>>>> We dont have any hook like postScan().. In ur case you can try >> with >>>>>>> postScannerClose().. This will be called once per region. When >> the >>>>>> scan on >>>>>>> that region is over the scanner opened on that region will get >>> closed >>>>>> and >>>>>>> at that time this hook will get executed. >>>>>>> >>>>>>> -Anoop- >>>>>>> ________________________________________ >>>>>>> From: Farrokh Shahriari [[EMAIL PROTECTED]] >>>>>>> Sent: Monday, February 18, 2013 10:27 AM >>>>>>> To: [EMAIL PROTECTED] >>>>>>> Cc: [EMAIL PROTECTED] >>>>>>> Subject: Re: Co-Processor in scanning the HBase's Table >>>>>>> >>>>>>> Thanks you Amit,I will check that. >>>>>>> @Anoop: I wanna run that just after scanning a region or after >>>> scanning >>>>>> the >>>>>>> regions that to belong to one regionserver. >>>>>>> >>>>>>> On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John < >> [EMAIL PROTECTED] >>>> >>>>>>> wrote: >>>>>>> >>>>>>>>> I wanna use a custom code after scanning a large table and >> prefer >>>> to >>>>>> run >>>>>>>> the code after scanning each region >>>>>>>> >>>>>>>> Exactly at what point you want to run your custom code? We have >>>>>> hooks at >>>>>>>> points like opening a scanner at a region, closing scanner at a >>>>>> region, >>>>>>>> calling next (pre/post) etc >>>>>>>> >>>>>>>> -Anoop- >>>>>>>> ________________________________________ >>>>>>>> From: Farrokh Shahriari [[EMAIL PROTECTED]] >>>>>>>> Sent: Monday, February 18, 2013 12:21 AM
-
Re: Co-Processor in scanning the HBase's Table
Anoop John 2013-02-22, 18:04
yes what Ted mentioned, u can try out.. -Anoop- On Fri, Feb 22, 2013 at 7:46 PM, Ted <[EMAIL PROTECTED]> wrote: > Hbase-5416 should help your use case. > Cf2 would be the essential column family. > > This feature is available in 0.94.5 > > Cheers > > On Feb 22, 2013, at 5:55 AM, Farrokh Shahriari < > [EMAIL PROTECTED]> wrote: > > > @Anoop : Here is my situation: I have 2 columnFamilies(cf1,cf2),5-50 > > qualifiers(they are variable),first I should check the value of > qualifiers > > in cf2,then if they equal to some values I'm going to get the values of > cf1 > > by that rowkey. > > > > @Amita: thank you.I will check that too. > > > > Farrokh > > On Thu, Feb 21, 2013 at 8:58 PM, Amit Sela <[EMAIL PROTECTED]> wrote: > > > >> I think that if your intention is to do some kind of scan filtering on > the > >> server side then maybe an EndPoint coprocessor would be more fitting. > >> You can iterate over the InternalScanner and return a Map<> with your > >> filtered values. > >> > >> You can also check this link: > >> > http://hbase-coprocessor-experiments.blogspot.co.il/2011/05/extending.html> >> > >> Good Luck! > >> > >> On Thu, Feb 21, 2013 at 5:52 PM, Anoop John <[EMAIL PROTECTED]> > wrote: > >> > >>> What is this filtering at client side doing exactly? > >>> postScannerClose() wont deal with any scanned data. This hook will be > >>> called later.. You should be using hooks with scanner's next calls. > >> Mind > >>> telling the exact thing you are doing now at client side. Then we might > >> be > >>> able to suggest some thing. > >>> > >>> -Anoop- > >>> > >>> On Thu, Feb 21, 2013 at 7:14 PM, Farrokh Shahriari < > >>> [EMAIL PROTECTED]> wrote: > >>> > >>>> Hello again, > >>>> I've used PostScannerClose Regionobserver as the hbase book > (Definitive > >>>> Guide) says,but it doesn't seem worked.And I noticed that the > >>>> PostScannerClose doesn't return any value like result. > >>>> In fact,I just wanna doing a simple job as described below: > >>>> Up to now,I've used a scanner to filter the columnFamily,then on the > >>> client > >>>> side ( means at the result loop), filtered some other things,now I > want > >>> to > >>>> do that after scanning each region to reduce the amount of return > >> results > >>>> to client. > >>>> > >>>> Please help me,I need it asap. > >>>> > >>>> Farrokh > >>>> > >>>> On Tue, Feb 19, 2013 at 9:03 PM, Farrokh Shahriari < > >>>> [EMAIL PROTECTED]> wrote: > >>>> > >>>>> Thanks you guys > >>>>> > >>>>> > >>>>> On Mon, Feb 18, 2013 at 12:00 PM, Amit Sela <[EMAIL PROTECTED]> > >>> wrote: > >>>>> > >>>>>> Yes... that was emailing half asleep... :) > >>>>>> > >>>>>> On Mon, Feb 18, 2013 at 7:23 AM, Anoop Sam John <[EMAIL PROTECTED] > >>> > >>>>>> wrote: > >>>>>> > >>>>>>> We dont have any hook like postScan().. In ur case you can try > >> with > >>>>>>> postScannerClose().. This will be called once per region. When > >> the > >>>>>> scan on > >>>>>>> that region is over the scanner opened on that region will get > >>> closed > >>>>>> and > >>>>>>> at that time this hook will get executed. > >>>>>>> > >>>>>>> -Anoop- > >>>>>>> ________________________________________ > >>>>>>> From: Farrokh Shahriari [[EMAIL PROTECTED]] > >>>>>>> Sent: Monday, February 18, 2013 10:27 AM > >>>>>>> To: [EMAIL PROTECTED] > >>>>>>> Cc: [EMAIL PROTECTED] > >>>>>>> Subject: Re: Co-Processor in scanning the HBase's Table > >>>>>>> > >>>>>>> Thanks you Amit,I will check that. > >>>>>>> @Anoop: I wanna run that just after scanning a region or after > >>>> scanning > >>>>>> the > >>>>>>> regions that to belong to one regionserver. > >>>>>>> > >>>>>>> On Mon, Feb 18, 2013 at 7:45 AM, Anoop Sam John < > >> [EMAIL PROTECTED] > >>>> > >>>>>>> wrote: > >>>>>>> > >>>>>>>>> I wanna use a custom code after scanning a large table and > >> prefer > >>>> to > >>>>>> run > >>>>>>>> the code after scanning each region > >>>>>>>> > >>>>>>>> Exactly at what point you want to run your custom code? We have
|
|