couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Filipe Manana (JIRA)" <>
Subject [jira] Updated: (COUCHDB-1027) More efficient implementation of the DB updater BTree functions
Date Mon, 17 Jan 2011 11:27:44 GMT


Filipe Manana updated COUCHDB-1027:

    Attachment: COUCHDB-1027.patch

> More efficient implementation of the DB updater BTree functions
> ---------------------------------------------------------------
>                 Key: COUCHDB-1027
>                 URL:
>             Project: CouchDB
>          Issue Type: Improvement
>          Components: Database Core
>            Reporter: Filipe Manana
>            Assignee: Filipe Manana
>         Attachments: COUCHDB-1027.patch
> Currently, some of the BTree functions (by_id BTree reduce function and and by_seq BTree
split function) traverse the same input lists several times to produce the output. This is
not optimal. For example, the btree_by_id_reduce function, for a database with 300 000+ documents,
can easily get a list of 50 or more #full_doc_info records. This functions traverses that
list 4 times - 2 filtered list comprehensions plus two length/1 calls.
> The following patch changes the implementation to produce the same output with a single
list traversal operation.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message