Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 86889 invoked from network); 12 Jan 2009 19:11:15 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 12 Jan 2009 19:11:15 -0000 Received: (qmail 72003 invoked by uid 500); 12 Jan 2009 19:11:14 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 71678 invoked by uid 500); 12 Jan 2009 19:11:13 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 71667 invoked by uid 99); 12 Jan 2009 19:11:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jan 2009 11:11:13 -0800 X-ASF-Spam-Status: No, hits=-4.0 required=10.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of john.bartak@autodesk.com designates 198.102.112.47 as permitted sender) Received: from [198.102.112.47] (HELO cut.autodesk.com) (198.102.112.47) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jan 2009 19:11:01 +0000 Received: from smtp.mgd.autodesk.com ([65.54.1.156]) by cut.autodesk.com (8.14.1/8.12.6) with ESMTP id n0CJAeHS002493 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO) for ; Mon, 12 Jan 2009 11:10:40 -0800 (PST) Received: from ADSK-NAMSG-02.MGDADSK.autodesk.com ([65.54.1.154]) by ADSK-TK5MHUB-01.MGDADSK.autodesk.com ([65.54.1.156]) with mapi; Mon, 12 Jan 2009 11:10:40 -0800 From: John Bartak To: "user@couchdb.apache.org" Date: Mon, 12 Jan 2009 11:10:38 -0800 Subject: RE: Error when running two requests to same view simultaneously Thread-Topic: Error when running two requests to same view simultaneously Thread-Index: AclzTI2YK2CTjAewSt6LbHuejvNzGABmocUQ Message-ID: References: <20090110164853.GI10545@delora.autosys.us> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org It appears that the latest code (0.9.0a733848) does fix the crash of the se= rver. I now get back a result string that has an error value of missing in= stead of the document: {"total_rows":2,"offset":0,"rows":[ {"id":"09e2fb54e77545c0aec61578fe041965","key":["repository.repositoryfile"= ,"ownerid","filename"],"value":null,"error":"missing"}, {"id":"8cc55e26dfb047b09f222d7967f2a047","key":["repository.repositoryfile"= , "ownerid","filename"],"value":null,"doc":{"_id":"8cc55e26dfb047b09f222d79= 67f2a047","_rev":"2138313893","OwnerId":"ownerId","Name":"filename"}} ]} I'll have to update my code to handle that, but that's no big deal. Unfortunately, I don't get back 412's when two threads attempt to update th= e same revision of a document simultaneously. This happens for both the bu= lk_docs api and the standard PUT api: [info] [<0.3374.0>] 192.168.200.1 - - 'GET' /fileinttests_20090112_105825_5= 01_1818439740/473dccb50cb54a57abe19e7687c491ce?rev=3D4134090793 200 [info] [<0.3371.0>] 192.168.200.1 - - 'GET' /fileinttests_20090112_105825_5= 01_1818439740/473dccb50cb54a57abe19e7687c491ce?rev=3D4134090793 200 [info] [<0.3371.0>] 192.168.200.1 - - 'PUT' /fileinttests_20090112_105825_5= 01_1818439740/473dccb50cb54a57abe19e7687c491ce 201 [info] [<0.3374.0>] 192.168.200.1 - - 'PUT' /fileinttests_20090112_105825_5= 01_1818439740/473dccb50cb54a57abe19e7687c491ce 201 In the two threads that I have running, I first get the document I want to = revise and I then update the revision. -----Original Message----- From: Chris Anderson [mailto:jchris@gmail.com] Sent: Saturday, January 10, 2009 9:54 AM To: user@couchdb.apache.org Subject: Re: Error when running two requests to same view simultaneously On Sat, Jan 10, 2009 at 8:48 AM, Michael McDaniel wrot= e: > The short answer is that there is no function couch_doc:to_json_doc/2 > that accepts the arguments ( {not_found, missing}, [] ) gracefully > >> {function_clause, >> [{couch_doc,to_json_obj,[{not_found,missing},[]]}, >> ... > The problem seems to have been in the error handling in the include_docs code. Do you mind updating to the latest trunk and attempting to recreate the error? It should be fixed. -- Chris Anderson http://jchris.mfdz.com