Return-Path: Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: (qmail 49646 invoked from network); 6 Jul 2009 15:26:29 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 6 Jul 2009 15:26:29 -0000 Received: (qmail 61591 invoked by uid 500); 6 Jul 2009 15:26:39 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 61524 invoked by uid 500); 6 Jul 2009 15:26:39 -0000 Mailing-List: contact dev-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list dev@couchdb.apache.org Received: (qmail 61395 invoked by uid 99); 6 Jul 2009 15:26:39 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Jul 2009 15:26:39 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Jul 2009 15:26:36 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 2381F29A001C for ; Mon, 6 Jul 2009 08:26:15 -0700 (PDT) Message-ID: <1728194340.1246893975144.JavaMail.jira@brutus> Date: Mon, 6 Jul 2009 08:26:15 -0700 (PDT) From: "Brad Anderson (JIRA)" To: dev@couchdb.apache.org Subject: [jira] Updated: (COUCHDB-389) [PATCH] Make offset calculation more available during btree folding In-Reply-To: <807846367.1245359647369.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/COUCHDB-389?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Brad Anderson updated COUCHDB-389: ---------------------------------- Attachment: couchdb-389-3.git.patch passes davisp muster. > [PATCH] Make offset calculation more available during btree folding > ------------------------------------------------------------------- > > Key: COUCHDB-389 > URL: https://issues.apache.org/jira/browse/COUCHDB-389 > Project: CouchDB > Issue Type: Improvement > Components: Database Core > Affects Versions: 0.9 > Reporter: Brad Anderson > Priority: Minor > Attachments: clustered_offset.patch, couchdb-389-2.svn.patch, couchdb-389-3.git.patch, couchdb-389.svn.patch > > > When CouchDB returns no values for _all_docs (or potentially any fold over the btree), then no offset is calculated, either. This is not a problem in non-clustered CouchDB. However, when you are in a clustered environment and treat each shard as its own CouchDB, then not returning an offset when no values are found on the shard can be problematic. The specific case is if there is a startkey or skip specified, and there were values before (or after with descending=true) the startkey or skip values, but there are no current values. > Moving the Offset calculation to be available for all clauses in the return fun of couch_httpd_view:make_view_fold_fun/6 allows the user to store Offsets in the RowFunAcc and client code using this function will work as expected. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.