hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "stack (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-12029) Use Table and RegionLocator in HTable.getRegionLocations()
Date Thu, 25 Sep 2014 00:24:38 GMT

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

stack commented on HBASE-12029:
-------------------------------

On the patch

... is the new method getAllRegionLocations a replacement for getRegionLocations?  (It makes
use of it...Its the preferred way going forward?)  If so, should the @deprecated have a note
added that points folks to the new method?

Does this metascanner get closed at all? +        ResultScanner metaScanner = metaTable.getScanner(scan);

That is nice the way you did convert to use reverse scan.

These look a little odd as additions to RegionLocator Interface?

+  HTableDescriptor getTableDescriptor() throws IOException;
+  Configuration getConfiguration();

You need them in there?  For configuration at least, you don't have a Connection in the RegionLocator
context you could get Configuration from?  Would be sweet if RegionLocator didn't have to
carry a HTD (Is it even used? It does not seem to be used in this patch).  I could see it
carrying a TableName...  if only to have some provenance on RegionLocator (Looks like it already
has this).

Removing unused method params is great.

Otherwise patch looks good to me.  +1







> Use Table and RegionLocator in HTable.getRegionLocations() 
> -----------------------------------------------------------
>
>                 Key: HBASE-12029
>                 URL: https://issues.apache.org/jira/browse/HBASE-12029
>             Project: HBase
>          Issue Type: Bug
>    Affects Versions: 2.0.0, 0.99.1
>            Reporter: Solomon Duskis
>            Assignee: Solomon Duskis
>         Attachments: HBASE-12029.patch, HBASE-12029_v1.patch, HBASE-12029_v2.patch, HBASE-12029_v3.patch,
HBASE-12029_v4.patch, HBASE-12029_v4.patch
>
>
> HTable.getRegionLocations() is an internal deprecated API.  There are plenty of internal
uses of the method, and it would be ideal to use the Table and RegionLocator interfaces instead
of the HTable method.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message