You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by "John Vines (JIRA)" <ji...@apache.org> on 2014/03/31 21:00:21 UTC

[jira] [Commented] (ACCUMULO-2594) Improve TabletLocator.getInstance() to check tableId points to a table which exists

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

John Vines commented on ACCUMULO-2594:
--------------------------------------

FTR, the TabletLocator is not part of the public API

> Improve TabletLocator.getInstance() to check tableId points to a table which exists
> -----------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-2594
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-2594
>             Project: Accumulo
>          Issue Type: Improvement
>          Components: client
>    Affects Versions: 1.5.0
>            Reporter: Ara Ebrahimi
>            Priority: Minor
>             Fix For: 1.5.2, 1.6.1
>
>
> If you pass an invalid tableId (or in my case tableName instead of tableId) TabletLocator won't complain.
> TabletLocator tabletLocator = TabletLocator.getInstance(instance, new Text(tableId));
> Next if you use the returned tabletLocator to locate a tablet it just returns an empty list, never complaining that the tableId was invalid:
> TabletLocator.TabletLocation tabletLocation = tabletLocator.locateTablet(rowKey.getText(), false, false, credentials.toThrift());
> Ideally TabletLocator.getInstance() should guard against invalid/non-existing tableIds.



--
This message was sent by Atlassian JIRA
(v6.2#6252)