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 567E8200C85 for ; Tue, 30 May 2017 17:30:29 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 554C3160BC9; Tue, 30 May 2017 15:30:29 +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 C1E3B160BC1 for ; Tue, 30 May 2017 17:30:28 +0200 (CEST) Received: (qmail 53636 invoked by uid 500); 30 May 2017 15:30:27 -0000 Mailing-List: contact dev-help@accumulo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@accumulo.apache.org Delivered-To: mailing list dev@accumulo.apache.org Received: (qmail 53625 invoked by uid 99); 30 May 2017 15:30:27 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 30 May 2017 15:30:27 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 8AA26DFE5C; Tue, 30 May 2017 15:30:27 +0000 (UTC) From: ivakegg To: dev@accumulo.apache.org Reply-To: dev@accumulo.apache.org References: In-Reply-To: Subject: [GitHub] accumulo pull request #260: ACCUMULO-4643 initial implementation Content-Type: text/plain Message-Id: <20170530153027.8AA26DFE5C@git1-us-west.apache.org> Date: Tue, 30 May 2017 15:30:27 +0000 (UTC) archived-at: Tue, 30 May 2017 15:30:29 -0000 Github user ivakegg commented on a diff in the pull request: https://github.com/apache/accumulo/pull/260#discussion_r119133690 --- Diff: server/tserver/src/main/java/org/apache/accumulo/tserver/tablet/Tablet.java --- @@ -586,6 +589,10 @@ private LookupResult lookup(SortedKeyValueIterator mmfi, List mmfi.next(); } + } catch (ScanYieldException sye) { + log.debug("Scan yield exception detected at position " + sye.getPosition()); + addUnfinishedRange(lookupResult, range, sye.getPosition(), false); --- End diff -- Each key that is actually returned by the iterator will be returned to the user. The ScanYieldException would be thrown within the next call (presumably because it has been doing a lot of scanning and not actually finding any keys to return). The key placed in the exception would where the next call left off before finding the next key to return. All keys already returned by getTopKey() after successfull next calls would still be returned appropriately. If you follow the timesUp or the exceededMemoryUsage used here, you will see that it is essentially follows the same paradigm of yielding the scan until later. I am just supplying a way for the underlying iterator to force this to happen. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. ---