You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Chia-Ping Tsai (JIRA)" <ji...@apache.org> on 2017/07/02 14:59:00 UTC

[jira] [Commented] (HBASE-18241) Change client.Table and client.Admin to not use HTableDescriptor

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

Chia-Ping Tsai commented on HBASE-18241:
----------------------------------------

v3.patch
There are plenty of changes as Region#getTableDesc() and Store#getFamily() are often used in code base.
--
*Region class*
||*Previous API*||*New API*||
|HTableDescriptor getTableDesc()|TableDescriptor getTableDescriptor()|

*Store class*
||*Previous API*||*New API*||
|HColumnDescriptor getFamily()|ColumnFamilyDescriptor getDescriptor()|

*Table class*
||*Deprecated API*||*New API*||
|HTableDescriptor getTableDescriptor()|TableDescriptor getDescriptor()|

*Admin class*
||*Deprecated API*||*New API*||
|HTableDescriptor getTableDescriptor(TableName)|List<TableDescriptor> listTableDescriptor(TableName)|
|HTableDescriptor[] getTableDescriptors(List<String>)|N/A|
|HTableDescriptor[] getTableDescriptorsByTableName(List<TableName>)|List<TableDescriptor> listTableDescriptors(List<TableName>)|
|HTableDescriptor[] listTables()|List<TableDescriptor> listTableDescriptors()|
|HTableDescriptor[] listTables(Pattern)|List<TableDescriptor> listTableDescriptors(Pattern)|
|HTableDescriptor[] listTables(String)|List<TableDescriptor> listTableDescriptors(String)|
|HTableDescriptor[] listTables(Pattern, boolean)|List<TableDescriptor> listTableDescriptors(Pattern, boolean)|
|HTableDescriptor[] listTables(String, boolean)|List<TableDescriptor> listTableDescriptors(String, boolean)|
|HTableDescriptor[] deleteTables(String)|N/A|
|HTableDescriptor[] deleteTables(Pattern)|N/A|
|HTableDescriptor[] enableTables(String)|N/A|
|HTableDescriptor[] enableTables(Pattern)|N/A|
|HTableDescriptor[] disableTables(String)|N/A|
|HTableDescriptor[] disableTables(Pattern)|N/A|
|void modifyTable(TableName, HTableDescriptor)|void modifyTable(TableDescriptor)|
|void modifyTableAsync(TableName, HTableDescriptor)|void modifyTableAsync(TableDescriptor)|
|HTableDescriptor[] listTableDescriptorsByNamespace(String)|List<TableDescriptor> listTableDescriptorsByNamespace(byte[])|

||*Previous API*||*New API*||
|void createTable({color:red}HTableDescriptor{color})|void createTable({color:red}TableDescriptor{color})|
|void createTable({color:red}HTableDescriptor{color}, byte[], byte[], int)|void createTable({color:red}TableDescriptor{color}, byte[], byte[], int)|
|void createTable({color:red}HTableDescriptor{color}, byte[][])|void createTable({color:red}TableDescriptor{color}, byte[][])|
|Future<Void> createTableAsync({color:red}HTableDescriptor{color}, byte[][])|Future<Void> createTableAsync({color:red}TableDescriptor{color}, byte[][])|


> Change client.Table and client.Admin to not use HTableDescriptor
> ----------------------------------------------------------------
>
>                 Key: HBASE-18241
>                 URL: https://issues.apache.org/jira/browse/HBASE-18241
>             Project: HBase
>          Issue Type: Task
>            Reporter: Biju Nair
>            Assignee: Chia-Ping Tsai
>            Priority: Critical
>             Fix For: 3.0.0, 2.0.0-alpha-2
>
>         Attachments: HBASE-18241.v0.patch, HBASE-18241.v1.patch, HBASE-18241.v2.patch, HBASE-18241.v2.patch
>
>
> {{HTableDescriptor}} is deprecated and scheduled to be removed in 3.0. But [client.Table|https://github.com/apache/hbase/blob/a66d491892514fd4a188d6ca87d6260d8ae46184/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Table.java#L69] and [client.Admin|https://github.com/apache/hbase/blob/a66d491892514fd4a188d6ca87d6260d8ae46184/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java#L198] method {{getTableDescriptor}} returns {{HTableDescriptor}}.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)