From dev-return-17835-apmail-couchdb-dev-archive=couchdb.apache.org@couchdb.apache.org Fri Aug 26 20:55:53 2011 Return-Path: X-Original-To: apmail-couchdb-dev-archive@www.apache.org Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B744081C2 for ; Fri, 26 Aug 2011 20:55:53 +0000 (UTC) Received: (qmail 74895 invoked by uid 500); 26 Aug 2011 20:55:52 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 74670 invoked by uid 500); 26 Aug 2011 20:55:52 -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 74646 invoked by uid 99); 26 Aug 2011 20:55:51 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Aug 2011 20:55:51 +0000 X-ASF-Spam-Status: No, hits=-2000.5 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Aug 2011 20:55:50 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 536C4D13C8 for ; Fri, 26 Aug 2011 20:55:29 +0000 (UTC) Date: Fri, 26 Aug 2011 20:55:29 +0000 (UTC) From: "Bob Dionne (JIRA)" To: dev@couchdb.apache.org Message-ID: <1421058951.19320.1314392129338.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (COUCHDB-911) Repeating a doc._id in a _bulk_docs request results in erroneous "Document conflict" error MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/COUCHDB-911?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Bob Dionne updated COUCHDB-911: ------------------------------- Attachment: (was: jira-911-patch.diff) > Repeating a doc._id in a _bulk_docs request results in erroneous "Document conflict" error > ------------------------------------------------------------------------------------------ > > Key: COUCHDB-911 > URL: https://issues.apache.org/jira/browse/COUCHDB-911 > Project: CouchDB > Issue Type: Bug > Components: HTTP Interface > Affects Versions: 1.0 > Environment: Cloudant BigCouch EC2 node > Reporter: Jay Nelson > Priority: Minor > Attachments: jira-911-patch2.diff > > Original Estimate: 48h > Remaining Estimate: 48h > > Repeating an "_id" in a _bulk_docs post data file results in both entries being reported as document conflict errors. The first occurrence actual inserts into the database, and only the second occurrence should report a conflict. > curl -d '{ "docs": [ {"_id":"foo"}, {"_id","foo"} ] }' -H 'Content-Type:application/json' -X POST http://appadvice.cloudant.com/foo/_bulk_docs > [{"id":"foo","error":"conflict","reason":"Document update conflict."},{"id":"foo","error":"conflict","reason":"Document update conflict."}] > But the database shows that one new document was actually inserted. > Only the second occurrence should report conflict. The first occurrence should report the "_rev" property of the newly inserted doc. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira