hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anoop Sam John <anoo...@huawei.com>
Subject RE: Find the tablename in Observer
Date Tue, 29 Jan 2013 06:04:34 GMT
Oh sorry...
Not checked the interface...  We were doing in postOpen()...
Thaks Gary for correcting me...:)

-Anoop-

________________________________________
From: Gary Helmling [ghelmling@gmail.com]
Sent: Tuesday, January 29, 2013 11:29 AM
To: user@hbase.apache.org
Subject: Re: Find the tablename in Observer

> >Will the CoprocessorEnvironment reference in the  start() method be
> instanceof RegionCoprocessorEnvironment too
>
> No. It will be reference of RegionEnvironment . This is not a public class
> so you wont be able to do the casting.
>

Since RegionEnvionment implements RegionCoprocessorEnvironment, you should
be able to do:

((RegionCoprocessorEnvironment)env).getRegion().getRegionInfo().getTableName();

within your start() method without a problem.
Mime
View raw message