hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zhihong Ted Yu (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-5061) StoreFileLocalityChecker
Date Fri, 06 Jul 2012 22:43:35 GMT

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

Zhihong Ted Yu commented on HBASE-5061:
---------------------------------------

Nice work.
{code}
+public class StoreFileLocalityChecker {
{code}
Should @InterfaceAudience.Private be added to the class ?
{code}
+    void reportTotals(double min, double max, double average) throws IOException;
{code}
Since total isn't included in the report, maybe there is a better name for the above method
?
{code}
+  private Pair<Path,HDFSBlocksDistribution> getBlocksForPath(Path path) 
{code}
Space after comma.
{code}
+      if (familyDir.getPath().toString().endsWith(".tmp")) {
+        continue;
{code}
Is there other directory that should be skipped ?
{code}
+        // Is the region assigned to the desired server?
+        byte[] value = row.getValue(HConstants.CATALOG_FAMILY, HConstants.SERVER_QUALIFIER);
+        if (value == null || value.length < serverName.length) {
+          return true;
+        }
{code}
If serverName is a prefix of value, the region would be included in the collection returned.
Is that intended ?
{code}
+  static class SimpleReporter implements Reporter {
{code}
The above class can be private, right ?
Same with JSONReporter class.
                
> StoreFileLocalityChecker
> ------------------------
>
>                 Key: HBASE-5061
>                 URL: https://issues.apache.org/jira/browse/HBASE-5061
>             Project: HBase
>          Issue Type: New Feature
>    Affects Versions: 0.96.0, 0.94.1
>            Reporter: Andrew Purtell
>            Assignee: Andrew Purtell
>            Priority: Minor
>         Attachments: HBASE-5061-0.94.patch, HBASE-5061-0.94.patch, HBASE-5061.patch,
HBASE-5061.patch
>
>
> org.apache.hadoop.hbase.HFileLocalityChecker [options]
> A tool to report the number of local and nonlocal HFile blocks, and the ratio of as a
percentage.
> Where options are:
> |-f <file>|Analyze a store file|
> |-r <region>|Analyze all store files for the region|
> |-t <table>|Analyze all store files for regions of the table served by the local
regionserver|
> |-h <host>|Consider <host> local, defaults to the local host|
> |-v|Verbose operation|

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message