couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Noah Slater (JIRA)" <j...@apache.org>
Subject [jira] Updated: (COUCHDB-16) _bulk_docs returns results in reverse order
Date Sat, 08 Mar 2008 23:57:46 GMT

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

Noah Slater updated COUCHDB-16:
-------------------------------

    Attachment: bulk_reverse_fix.diff

> _bulk_docs returns results in reverse order
> -------------------------------------------
>
>                 Key: COUCHDB-16
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-16
>             Project: CouchDB
>          Issue Type: Bug
>            Reporter: Noah Slater
>            Priority: Minor
>         Attachments: bulk_reverse_fix.diff, reverse_bulk_results_test.diff
>
>
> Posting to /database/_bulk_docs will return a JSON object which looks like
> this:
>       {
>         "ok": true,
>         "results": [
>           {"ok":true,"id":"a","rev":"3465402201"},
>           {"ok":true,"id":"b","rev":"914573466"},
>           {"ok":true,"id":"c","rev":"2541681057"}
>         ]
>       }
> however, the "results" part of these response orders the docResults
> opposite of the array posted to _bulk_docs.
> I've attached a unit test which demonstrates this.
> -- ry@tinyclouds.org
> --
> Comment 2 by coldredlemur, Dec 25, 2007
> Actually, replacing the foldl with a  foldr in mod_couch:handle_bulk_doc_update fixes
the problem. (I don't  
> know what's going on in that function, so someone should verify that this is the accurate
fix.)
> -- ry

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


Mime
View raw message