[ 
https://issues.apache.org/jira/browse/HBASE-22903?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16917002#comment-16917002
 ] 

Viraj Jasani edited comment on HBASE-22903 at 8/27/19 7:04 PM:
---------------------------------------------------------------

Thanks for the suggestion [~stack] 
{quote}If the shell starts the alter, it should keep the future returned and 
poll it?
{quote}
This seems really great. However, if schema is updated by coprocessor or due to 
peer replication, it might not be useful?(I am just giving a thought, I am not 
100% sure)

Also, this might not be the best case to think about but if we have master 
failover, without Admin method, it might be difficult for this command to get 
status? Yes, in general, I agree with polling scenario or having a generic 
getStatus(), but this command essentially let us know how many regions are in 
RIT at a moment and hence, AssignmentManager is the best source of truth may 
be? Hence, this Admin method should be used?

Moreover, this command keeps printing the status of how many regions are done 
with transition until all are done(with 1 sec interval 
[here|https://github.com/apache/hbase/blob/5106f2826ef650f67977497b305b35953213a045/hbase-shell/src/main/ruby/hbase/admin.rb#L660]).
 Without Admin(eventually AM), getting info about RIT(with consistency) might 
be difficult? Or may be I am missing something.

e.g. getClusterMetrics() or getRegionMetrics() would require RPC from Admin, 
similarly with alter_status also, we would require RPC and better to use Admin 
interface?

Please let me know if I am not going to the right direction. Thanks you!


was (Author: vjasani):
Thanks for the suggestion [~stack] 
{quote}If the shell starts the alter, it should keep the future returned and 
poll it?
{quote}
This seems really great. However, if schema is updated by coprocessor or due to 
peer replication, it might not be useful?(I am just giving a thought, I am not 
100% sure)

Also, this might not be the best case to think about but if we have master 
failover, without Admin method, it might be difficult for this command to get 
status? Yes, in general, I agree with polling scenario or having a generic 
getStatus(), but this command essentially let us know how many regions are in 
RIT at a moment and hence, AssignmentManager is the best source of truth may 
be? Hence, this Admin method should be used?

Moreover, this command keeps printing the status of how many regions are done 
with transition until all are done(with 1 sec interval 
[here|https://github.com/apache/hbase/blob/5106f2826ef650f67977497b305b35953213a045/hbase-shell/src/main/ruby/hbase/admin.rb#L660]).
 Without Admin(eventually AM), getting info about RIT(with consistency) might 
be difficult? Or may be I am missing something.

> alter_status command is broken
> ------------------------------
>
>                 Key: HBASE-22903
>                 URL: https://issues.apache.org/jira/browse/HBASE-22903
>             Project: HBase
>          Issue Type: Bug
>          Components: Admin, asyncclient, shell
>    Affects Versions: 3.0.0
>            Reporter: Viraj Jasani
>            Assignee: Viraj Jasani
>            Priority: Major
>             Fix For: 3.0.0
>
>         Attachments: HBASE-22903.master.000.patch, 
> HBASE-22903.master.001.patch, HBASE-22903.master.002.patch
>
>
> This is applicable to master branch only:
> {code:java}
> > alter_status 't1'
> ERROR: undefined method `getAlterStatus' for 
> #<Java::OrgApacheHadoopHbaseClient::AdminOverAsyncAdmin:0x252ec02e>
> {code}
>  



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

Reply via email to