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 F0798200C5C for ; Thu, 6 Apr 2017 00:32:45 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id EEDC8160BA3; Wed, 5 Apr 2017 22:32:45 +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 41D10160B94 for ; Thu, 6 Apr 2017 00:32:45 +0200 (CEST) Received: (qmail 36755 invoked by uid 500); 5 Apr 2017 22:32:44 -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 36743 invoked by uid 99); 5 Apr 2017 22:32:44 -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:32:44 +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 E8DB01813A4 for ; Wed, 5 Apr 2017 22:32:43 +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-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id gh7x8pVWOIYA for ; Wed, 5 Apr 2017 22:32:42 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id 890DA5F1A0 for ; Wed, 5 Apr 2017 22:32:42 +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 0DEB2E04AB for ; Wed, 5 Apr 2017 22:32: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 C1787263C4 for ; Wed, 5 Apr 2017 22:32:41 +0000 (UTC) Date: Wed, 5 Apr 2017 22:32:41 +0000 (UTC) From: "Tomu Tsuruhara (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (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: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 05 Apr 2017 22:32:46 -0000 [ https://issues.apache.org/jira/browse/HBASE-17871?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D159= 57920#comment-15957920 ]=20 Tomu Tsuruhara commented on HBASE-17871: ---------------------------------------- @Ted Yu 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:=20 !=E3=82=B9=E3=82=AF=E3=83=AA=E3=83=BC=E3=83=B3=E3=82=B7=E3=83=A7=E3=83=83= =E3=83=88 2017-04-06 7.19.53.png|thumbnail=3D1! after: !=E3=82=B9=E3=82=AF=E3=83=AA=E3=83=BC=E3=83=B3=E3=82=B7=E3=83=A7=E3=83=83= =E3=83=88 2017-04-06 7.21.53.png|thumbnail=3D1! > 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: 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.re= plication.VerifyReplication: CONTENT_DIFFERENT_ROWS, rowkey=3Da000010019300= 00 > 2017-04-03 23:30:50,280 ERROR [main] org.apache.hadoop.hbase.mapreduce.re= plication.VerifyReplication: ONLY_IN_PEER_TABLE_ROWS, rowkey=3Da00001001930= 000 > 2017-04-03 23:30:50,387 ERROR [main] org.apache.hadoop.hbase.mapreduce.re= plication.VerifyReplication: CONTENT_DIFFERENT_ROWS, rowkey=3Da000010038500= 00 > 2017-04-03 23:30:50,414 ERROR [main] org.apache.hadoop.hbase.mapreduce.re= plication.VerifyReplication: ONLY_IN_PEER_TABLE_ROWS, rowkey=3Da00001003850= 000 > 2017-04-03 23:30:50,480 ERROR [main] org.apache.hadoop.hbase.mapreduce.re= plication.VerifyReplication: CONTENT_DIFFERENT_ROWS, rowkey=3Da000010053200= 00 > 2017-04-03 23:30:50,508 ERROR [main] org.apache.hadoop.hbase.mapreduce.re= plication.VerifyReplication: ONLY_IN_PEER_TABLE_ROWS, rowkey=3Da00001005320= 000 > {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 =3D=3D null) { > =09 ... > final Scan scan =3D new Scan(); > scan.setBatch(batch); > {code} > As stated in HBASE-16376, {{scan#setBatch(int)}} call implicitly allows s= can results to be partial. > Since {{VerifyReplication}} is assuming each {{scanner.next()}} call retu= rns 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/h= base/entry/scan_improvements_in_hbase_1), > it's safe and acceptable I think. -- This message was sent by Atlassian JIRA (v6.3.15#6346)