Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Plain View
HBase, mail # user - Base coprocessor arguments


+
George Forman 2012-08-20, 13:48
+
Ben Kim 2013-09-11, 09:25
Copy link to this message
-
Re: Base coprocessor arguments
Gary Helmling 2013-09-11, 23:23
Ben & George,

The arguments you provide when configuring the coprocessor should be
present in the Configuration object exposed through
CoprocessorEnvironment.  So, for example, in your RegionObserver.start()
method, you should be able to do:

*public void start(CoprocessorEnvironment e) throws IOException {
*
* *e.getConfiguration().get("arg1"); // should be "1"*
*
*}
*
On Wed, Sep 11, 2013 at 2:25 AM, Ben Kim <[EMAIL PROTECTED]> wrote:

> Hello George
>
> Have you found a solution to your question?
>
> I can't seem to get the arguments anywhere :(
>
> Best,
> Ben
>
> *Benjamin Kim*
> *benkimkimben at gmail*
>
>
> On Mon, Aug 20, 2012 at 10:48 PM, George Forman
> <[EMAIL PROTECTED]>wrote:
>
> >
> >
> > Hi All,
> > I have extended BaseRegionObservers coprocessor. I want to know how to
> > access the arguments specified with the associated table: alter 't1',
> > METHOD => 'table_att',
> >
> >
> 'coprocessor'=>'hdfs:///foo.jar|com.foo.FooRegionObserver|1001|arg1=1,arg2=2'
> > Are they available in postPut via
> > ObserverContext<RegionCoprocessorEnvironment> ?
> > Thanks
> > George
>
+
Ben Kim 2013-09-12, 04:19