hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bhupendra Kumar Jain (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-17779) disable_table_replication returns misleading message and does not turn off repliaton
Date Tue, 14 Mar 2017 09:10:41 GMT

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

Bhupendra Kumar Jain commented on HBASE-17779:

Patch looks fine. Just few comments
1. Please change existing parameter name from "isRepEnabled" to "enableRep"  ( I think that
is more meaningful )
2. Assign the result of isTableRepEnabled(htd) to a variable and use in if statement. ( To
avoid calling isTableRepEnabled twice)

bq. In this one enable_table_replication and disable_table_replication always sets the replication
scope for a given table, so there is no need to propagate other info to the user. 
Yes, No need to propagate other info the user. We can probably add separate public API for
user to know the replication state. 
bq. Also it is a behavior change.
The patch corrects the current behavior which IMO was a bug.

> disable_table_replication returns misleading message and does not turn off repliaton
> ------------------------------------------------------------------------------------
>                 Key: HBASE-17779
>                 URL: https://issues.apache.org/jira/browse/HBASE-17779
>             Project: HBase
>          Issue Type: Bug
>            Reporter: Ted Yu
>            Assignee: Janos Gub
>         Attachments: HBASE-17779.patch
> Currently HBaseAdmin#isTableRepEnabled() returns false if ANY of the columns families
is not replicated.
> Because of this if you have a table where replication is partially enabled, calling disable_table_replication
will not have any effect, but will report that replication for a given table is disabled.
> Workaround is enabling table replication before disabling. 
> As a solution quoted from HBASE-17460:
> Admin#disableTableReplication() returns nothing and isTableRepEnabled() returns boolean.
For master branch, we can let isTableRepEnabled() return enum (partially disabled, disabled,
etc) This way, Admin#disableTableReplication() can return meaningful value to the user.

This message was sent by Atlassian JIRA

View raw message