Return-Path: Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: (qmail 86101 invoked from network); 6 Aug 2010 16:56:51 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 6 Aug 2010 16:56:51 -0000 Received: (qmail 92732 invoked by uid 500); 6 Aug 2010 16:56:51 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 92678 invoked by uid 500); 6 Aug 2010 16:56:50 -0000 Mailing-List: contact commits-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 commits@couchdb.apache.org Received: (qmail 92671 invoked by uid 99); 6 Aug 2010 16:56:50 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 06 Aug 2010 16:56:50 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 06 Aug 2010 16:56:49 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 506B223889ED; Fri, 6 Aug 2010 16:55:33 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r983052 - /couchdb/branches/0.11.x/src/couchdb/couch_httpd_db.erl Date: Fri, 06 Aug 2010 16:55:33 -0000 To: commits@couchdb.apache.org From: rnewson@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20100806165533.506B223889ED@eris.apache.org> Author: rnewson Date: Fri Aug 6 16:55:32 2010 New Revision: 983052 URL: http://svn.apache.org/viewvc?rev=983052&view=rev Log: add Etag header for standalone attachment PUT. Modified: couchdb/branches/0.11.x/src/couchdb/couch_httpd_db.erl Modified: couchdb/branches/0.11.x/src/couchdb/couch_httpd_db.erl URL: http://svn.apache.org/viewvc/couchdb/branches/0.11.x/src/couchdb/couch_httpd_db.erl?rev=983052&r1=983051&r2=983052&view=diff ============================================================================== --- couchdb/branches/0.11.x/src/couchdb/couch_httpd_db.erl (original) +++ couchdb/branches/0.11.x/src/couchdb/couch_httpd_db.erl Fri Aug 6 16:55:32 2010 @@ -1041,7 +1041,8 @@ db_attachment_req(#httpd{method=Method,m 'DELETE' -> {200, []}; _ -> - {201, [{"Location", absolute_uri(Req, "/" ++ + {201, [{"Etag", "\"" ++ ?b2l(couch_doc:rev_to_str(UpdatedRev)) ++ "\""}, + {"Location", absolute_uri(Req, "/" ++ binary_to_list(DbName) ++ "/" ++ binary_to_list(DocId) ++ "/" ++ binary_to_list(FileName)