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

Allan Yang commented on HBASE-21185:
------------------------------------

{code}
+          op.put("total_size_sum", new Long(cell.getFamilyLength() +
+              cell.getQualifierLength() +
+              cell.getRowLength() +
+              cell.getTagsLength() +
+              cell.getValueLength()));
         }
{code}
You forget there is a timestamp in cells which takes 8 bytes. You should used 
method in CellUtils class avoiding writing method yourself to make better 
encapsulation. For this case, you can use getSumOfCellElementLengths(making it 
public first). 

> WALPrettyPrinter: Additional useful info to be printed by wal printer tool, 
> for debugability purposes
> -----------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-21185
>                 URL: https://issues.apache.org/jira/browse/HBASE-21185
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Wellington Chevreuil
>            Assignee: Wellington Chevreuil
>            Priority: Trivial
>         Attachments: HBASE-21185.master.001.patch
>
>
> *WALPrettyPrinter* is very useful for troubleshooting wal issues, such as 
> faulty replication sinks. An useful information one might want to track is 
> the size of a single WAL entry edit, as well as size for each edit cell. Am 
> proposing a patch that adds calculations for these two, as well an option to 
> seek straight to a given position on the WAL file being analysed.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to