You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Enis Soztutar (JIRA)" <ji...@apache.org> on 2015/10/13 20:29:05 UTC
[jira] [Commented] (HBASE-14491)
ReplicationSource#countDistinctRowKeys code logic is not correct
[ https://issues.apache.org/jira/browse/HBASE-14491?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14955419#comment-14955419 ]
Enis Soztutar commented on HBASE-14491:
---------------------------------------
The patch for HBASE-14501 contains the change: {{lastCell = cells.get(i)}}. Sorry, I did not see this issue before.
As for sorting, if cells within WAL edits are not sorted, we should NOT sort them or allocate a new set to do the counting. distinctRowKeys is only used for the metric replicatedOperations and it will be expensive to allocate new objects just for this metric.
> ReplicationSource#countDistinctRowKeys code logic is not correct
> ----------------------------------------------------------------
>
> Key: HBASE-14491
> URL: https://issues.apache.org/jira/browse/HBASE-14491
> Project: HBase
> Issue Type: Bug
> Reporter: Ashish Singhi
> Assignee: Ashish Singhi
> Priority: Minor
>
> {code}
> Cell lastCell = cells.get(0);
> for (int i = 0; i < edit.size(); i++) {
> if (!CellUtil.matchingRow(cells.get(i), lastCell)) {
> distinctRowKeys++;
> }
> }
> {code}
> The above logic for finding the distinct row keys in the list needs to be corrected.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)