From dev-return-19331-apmail-couchdb-dev-archive=couchdb.apache.org@couchdb.apache.org Fri Nov 18 19:11:17 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 40E319979 for ; Fri, 18 Nov 2011 19:11:17 +0000 (UTC) Received: (qmail 96266 invoked by uid 500); 18 Nov 2011 19:11:16 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 96213 invoked by uid 500); 18 Nov 2011 19:11:15 -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 96166 invoked by uid 99); 18 Nov 2011 19:11:15 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 18 Nov 2011 19:11:15 +0000 X-ASF-Spam-Status: No, hits=-2001.2 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, 18 Nov 2011 19:11:11 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id E5B788D31B for ; Fri, 18 Nov 2011 19:10:51 +0000 (UTC) Date: Fri, 18 Nov 2011 19:10:51 +0000 (UTC) From: "Bob Dionne (Updated) (JIRA)" To: dev@couchdb.apache.org Message-ID: <1739496836.44521.1321643451942.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (COUCHDB-911) Concurrent updates to the same document generate erroneous conflict messages 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: 0003-Add-references-to-docs-to-prevent-dups-from-being-co.patch Thanks Filipe, I ran the test fine and modified the patch to conform to the couchdb style > Concurrent updates to the same document generate erroneous conflict messages > ---------------------------------------------------------------------------- > > 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 > Fix For: 1.2 > > Attachments: 0001-Add-test-test-etap-074-doc-update-conflicts.t.patch, 0001-Add-test-test-etap-074-doc-update-conflicts.t.patch, 0001-Fix-whitespace.patch, 0002-Failing-test-for-duplicates-in-bulk-docs.patch, 0003-Add-references-to-docs-to-prevent-dups-from-being-co.patch > > 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. 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