Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 768CD200C5C for ; Thu, 6 Apr 2017 00:39:47 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 74F9B160B9E; Wed, 5 Apr 2017 22:39:47 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id BB28E160B94 for ; Thu, 6 Apr 2017 00:39:46 +0200 (CEST) Received: (qmail 60002 invoked by uid 500); 5 Apr 2017 22:39:45 -0000 Mailing-List: contact issues-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@hbase.apache.org Received: (qmail 59991 invoked by uid 99); 5 Apr 2017 22:39:45 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Apr 2017 22:39:45 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 7E3091813A4 for ; Wed, 5 Apr 2017 22:39:45 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id VbovseSEiEzi for ; Wed, 5 Apr 2017 22:39:44 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 9AC315F24E for ; Wed, 5 Apr 2017 22:39:43 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 57759E0B08 for ; Wed, 5 Apr 2017 22:39:42 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id C2A91263C8 for ; Wed, 5 Apr 2017 22:39:41 +0000 (UTC) Date: Wed, 5 Apr 2017 22:39:41 +0000 (UTC) From: "Tomu Tsuruhara (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Comment Edited] (HBASE-17871) scan#setBatch(int) call leads wrong result of VerifyReplication MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 05 Apr 2017 22:39:47 -0000 [ https://issues.apache.org/jira/browse/HBASE-17871?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15957920#comment-15957920 ] Tomu Tsuruhara edited comment on HBASE-17871 at 4/5/17 10:38 PM: ----------------------------------------------------------------- Thanks! Addressed findbugs warning in v3 patch. "--batch" parsing code was introduced in HBASE-15191. We don't need to put extra code this time. > Have you verified the change fixes the inconsistency ? Yes, I confirmed that in my environment. before the patch: !beforethepatch.png|width=600! after: !after.png|width=600! was (Author: tomu.tsuruhara): Thanks! Addressed findbugs warning in v3 patch. "--batch" parsing code was introduced in HBASE-15191. We don't need to put extra code this time. > Have you verified the change fixes the inconsistency ? Yes, I confirmed that in my environment. before the patch: !beforethepatch.png|width=100! after: !after.png|width=100! > scan#setBatch(int) call leads wrong result of VerifyReplication > --------------------------------------------------------------- > > Key: HBASE-17871 > URL: https://issues.apache.org/jira/browse/HBASE-17871 > Project: HBase > Issue Type: Bug > Affects Versions: 2.0.0, 1.4.0 > Reporter: Tomu Tsuruhara > Assignee: Tomu Tsuruhara > Priority: Minor > Attachments: after.png, beforethepatch.png, HBASE-17871.master.001.patch, HBASE-17871.master.002.patch, HBASE-17871.master.003.patch > > > VerifyReplication tool printed weird logs. > {noformat} > 2017-04-03 23:30:50,252 ERROR [main] org.apache.hadoop.hbase.mapreduce.replication.VerifyReplication: CONTENT_DIFFERENT_ROWS, rowkey=a00001001930000 > 2017-04-03 23:30:50,280 ERROR [main] org.apache.hadoop.hbase.mapreduce.replication.VerifyReplication: ONLY_IN_PEER_TABLE_ROWS, rowkey=a00001001930000 > 2017-04-03 23:30:50,387 ERROR [main] org.apache.hadoop.hbase.mapreduce.replication.VerifyReplication: CONTENT_DIFFERENT_ROWS, rowkey=a00001003850000 > 2017-04-03 23:30:50,414 ERROR [main] org.apache.hadoop.hbase.mapreduce.replication.VerifyReplication: ONLY_IN_PEER_TABLE_ROWS, rowkey=a00001003850000 > 2017-04-03 23:30:50,480 ERROR [main] org.apache.hadoop.hbase.mapreduce.replication.VerifyReplication: CONTENT_DIFFERENT_ROWS, rowkey=a00001005320000 > 2017-04-03 23:30:50,508 ERROR [main] org.apache.hadoop.hbase.mapreduce.replication.VerifyReplication: ONLY_IN_PEER_TABLE_ROWS, rowkey=a00001005320000 > {noformat} > Here, each bad rows were marked as both {{CONTENT_DIFFERENT_ROWS}} and {{ONLY_IN_PEER_TABLE_ROWS}}. > This should never happen so I took a look at code and found scan.setBatch call. > {code} > @Override > public void map(ImmutableBytesWritable row, final Result value, > Context context) > throws IOException { > if (replicatedScanner == null) { > ... > final Scan scan = new Scan(); > scan.setBatch(batch); > {code} > As stated in HBASE-16376, {{scan#setBatch(int)}} call implicitly allows scan results to be partial. > Since {{VerifyReplication}} is assuming each {{scanner.next()}} call returns entire row, > partial results break compare logic. > We should avoid setBatch call here. > Thanks to RPC chunking (explained in this blog https://blogs.apache.org/hbase/entry/scan_improvements_in_hbase_1), > it's safe and acceptable I think. -- This message was sent by Atlassian JIRA (v6.3.15#6346)