HBASE-25497 move_namespaces_rsgroup should change hbase.rsgroup.name … (#2875)
* HBASE-25497 move_namespaces_rsgroup should change hbase.rsgroup.name config in NamespaceDescriptor Signed-off-by: Zheng Wang <wangzheng@apache.org>
This commit is contained in:
parent
d5debe15b5
commit
9e9bec24d2
|
@ -31,6 +31,10 @@ CMD
|
|||
|
||||
def command(dest, namespaces)
|
||||
rsgroup_admin.move_namespaces(dest, namespaces)
|
||||
namespaces.each do |ns|
|
||||
arg = {'METHOD' => 'set', 'hbase.rsgroup.name' => dest}
|
||||
admin.alter_namespace(ns, arg)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -114,8 +114,16 @@ module Hbase
|
|||
assert_not_nil(group)
|
||||
assert_true(@admin.listTablesInRSGroup(group_name).contains(org.apache.hadoop.hbase.TableName.valueOf(ns_table_name)))
|
||||
|
||||
ns_table_name2 = 'test_namespace:test_ns_table2'
|
||||
@shell.command(:create, ns_table_name2, 'f')
|
||||
|
||||
assert_true(@admin.listTablesInRSGroup(group_name).contains(org.apache.hadoop.hbase.TableName.valueOf(ns_table_name2)))
|
||||
assert_equal(2, @admin.listTablesInRSGroup(group_name).count)
|
||||
|
||||
@shell.command(:disable, ns_table_name)
|
||||
@shell.command(:drop, ns_table_name)
|
||||
@shell.command(:disable, ns_table_name2)
|
||||
@shell.command(:drop, ns_table_name2)
|
||||
@shell.command(:drop_namespace, namespace_name)
|
||||
remove_rsgroup(group_name)
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue