You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Sam Bisbee (Closed) (JIRA)" <ji...@apache.org> on 2012/02/22 06:44:53 UTC

[jira] [Closed] (COUCHDB-389) [PATCH] Make offset calculation more available during btree folding

     [ https://issues.apache.org/jira/browse/COUCHDB-389?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sam Bisbee closed COUCHDB-389.
------------------------------


Resolved for a while. Closing.
                
> [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
>            Assignee: Paul Joseph Davis
>            Priority: Minor
>             Fix For: 0.10
>
>         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.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira