Return-Path: X-Original-To: apmail-hbase-user-archive@www.apache.org Delivered-To: apmail-hbase-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 85D3618EFA for ; Mon, 8 Jun 2015 17:04:44 +0000 (UTC) Received: (qmail 27212 invoked by uid 500); 8 Jun 2015 17:04:40 -0000 Delivered-To: apmail-hbase-user-archive@hbase.apache.org Received: (qmail 27152 invoked by uid 500); 8 Jun 2015 17:04:40 -0000 Mailing-List: contact user-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hbase.apache.org Delivered-To: mailing list user@hbase.apache.org Received: (qmail 27137 invoked by uid 99); 8 Jun 2015 17:04:40 -0000 Received: from Unknown (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 08 Jun 2015 17:04:40 +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 8F498181A3C for ; Mon, 8 Jun 2015 17:04:39 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 3.13 X-Spam-Level: *** X-Spam-Status: No, score=3.13 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, HTML_MESSAGE=3, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id YiFPkHLK5zXY for ; Mon, 8 Jun 2015 17:04:35 +0000 (UTC) Received: from mail-ig0-f180.google.com (mail-ig0-f180.google.com [209.85.213.180]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTPS id CDC5C275E9 for ; Mon, 8 Jun 2015 17:04:34 +0000 (UTC) Received: by igbsb11 with SMTP id sb11so61855248igb.0 for ; Mon, 08 Jun 2015 10:03:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=G+pD2CRLh5TSFbAlTgxCqrdVYgZmUnmrkSR/Gt6dFok=; b=o5hX4lkxGQZEmLdHsQgJff+73Yh2d2ClXEJvzZxXlg23p1sEs8XHHEc/KVqc2bJeGQ OdFKY8qpZxmE2zTdJWk9O7hTEkDUvKwDWpwvOrnnPOHwdRa/8wj5szSVKjInWEYeuY3m iCl1QR2xMgLMAY8P96BBSRo2RebWyVpzG7Lv6WOjhCR6qxHeytFUYXTqiGzUe7hG5pj5 xK8OlVV19blGoFsV/Gu1tLY7L+pqQQS/vVzQuGDIDzNa3VvkqrRv88Eh31GPPfsZmDMG vB1bD7HTza1zKwaCNx4CqRi9pa2u2zYxPTcNrm7Hw30UXnQh4kWXAgcZMEHJnvopfstT zFoQ== MIME-Version: 1.0 X-Received: by 10.50.43.131 with SMTP id w3mr14693086igl.8.1433783023363; Mon, 08 Jun 2015 10:03:43 -0700 (PDT) Received: by 10.107.181.83 with HTTP; Mon, 8 Jun 2015 10:03:43 -0700 (PDT) In-Reply-To: References: Date: Mon, 8 Jun 2015 10:03:43 -0700 Message-ID: Subject: Re: Iterate hbase resultscanner From: beeshma r To: user@hbase.apache.org Content-Type: multipart/alternative; boundary=047d7bfea186caf3380518049f18 --047d7bfea186caf3380518049f18 Content-Type: text/plain; charset=UTF-8 Hi Ted I declared Listclass as public static List map_list_main=new ArrayList(); i know my logic is correct .only issue is adding my result to this Listclass.Also my conversion works perfectly .i checked this based on print out put results. only issue is why final element of Listclass updated for all elements in list I am using hbase version hbase-0.98.6.1 Hadoop -2.5.1 Also i using finagle client ,server module.So can u advise How do i debug this? Thanks Beeshma On Mon, Jun 8, 2015 at 9:24 AM, Ted Yu wrote: > From your description, the conversion inside for(Result rs:ListofResult) > loop was correct. > > Since Listclass is custom, probably you need to show us how it is > implemented. > > Which hbase release are you using ? > > On Mon, Jun 8, 2015 at 9:19 AM, beeshma r wrote: > > > HI > > > > I have weired issue with Hbase Result Scanner > > > > This is my scenario > > > > i have a list of Resultscanner(ListofScanner) > > from this Resultscanner list i want extract all results as list of > > result(ListofResult) > > and from result list i want iterate all cell values add to custom > class > > list (Listclass) > > > > So i coded like this > > > > for(ResultScanner resca:ListofScanner) > > { > > for(Result Res:resca) > > { > > > > ListofResult.add(Res); > > > > > > } > > } > > > > > > for(Result rs:ListofResult) > > { > > > > Listclass.add(Conver(rs));//Conver is function that converts results > and > > return as a my class object > > > > } > > > > Here is the O/p > > > > suppose i expect this result form Listclass if a print a all values > > > > gattner > > lisa > > Miely > > luzz > > > > But actual list i got > > > > luzz > > luzz > > luzz > > luzz > > > > The last element of Listclass is got updated to all values > > > > I checked for each Result output after conversion ( Conver(rs) ) it > returns > > as expected. But only issue adding Listofclass. > > > > Also i run with maven exec:java command(org.codehaus.mojo) .Break point > > also not working for me :( > > Please give me advice how to debug this. > > > > > > > > Thanks > > Beeshma > > > -- --047d7bfea186caf3380518049f18--