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 80AA811510 for ; Sat, 31 May 2014 19:07:23 +0000 (UTC) Received: (qmail 54047 invoked by uid 500); 31 May 2014 19:07:22 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 53990 invoked by uid 500); 31 May 2014 19:07:22 -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 53974 invoked by uid 99); 31 May 2014 19:07:22 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 31 May 2014 19:07:22 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of joant@lrtw.org designates 204.11.51.157 as permitted sender) Received: from [204.11.51.157] (HELO smtp.justsomehost.net) (204.11.51.157) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 31 May 2014 19:07:17 +0000 Received: from localhost (localhost [127.0.0.1]) by smtp.justsomehost.net (Postfix) with ESMTP id 095E336B0A; Sat, 31 May 2014 15:06:56 -0400 (EDT) X-Virus-Scanned: amavisd-new at jsent.ca Received: from smtp.justsomehost.net ([127.0.0.1]) by localhost (smtp.justsomehost.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9fW7K5dmuGy5; Sat, 31 May 2014 15:06:55 -0400 (EDT) Received: from smtp.justsomehost.net (smtp.justsomehost.net [204.11.51.157]) by smtp.justsomehost.net (Postfix) with ESMTP id F0FF436B09; Sat, 31 May 2014 15:06:54 -0400 (EDT) Date: Sat, 31 May 2014 15:06:54 -0400 (EDT) From: Joan Touzet To: dev@couchdb.apache.org Cc: user@couchdb.apache.org Message-ID: <25393204.61.1401563211286.JavaMail.jtouzet@jtouzet> In-Reply-To: <5389CC71.3050109@nospam.yrnm.net> Subject: Re: Proposal for new feature: Auto Update Functions MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Originating-IP: [69.165.165.30] X-Mailer: Zimbra 6.0.10_GA_2692 (Zimbra Desktop/7.2.5_12038_Windows) X-Virus-Checked: Checked by ClamAV on apache.org The typical solution to this is to use a reverse proxy or API layer to ensu= re that all client updates go through the required document update handler.= It's unclear to me that this functionality native in CouchDB is necessary. If you decide to move ahead with implementation , keep in mind that the 184= 3-feature-bigcouch branch as that will be landing very soon. Any proposed p= atch should be compatible the fabric/chttpd-based approach and support sing= le- and multi-node (BigCouch cluster) approaches. -Joan ----- Original Message ----- From: "Franck Eyraud" To: dev@couchdb.apache.org Cc: user@couchdb.apache.org Sent: Saturday, May 31, 2014 8:34:57 AM Subject: Re: Proposal for new feature: Auto Update Functions Le 30/05/2014 13:04, Dirkjan Ochtman a =C3=A9crit : > On Fri, May 30, 2014 at 12:57 PM, Suraj Kumar wr= ote: >> What are your thoughts, both from the use-case as well as >> internals/performance of CouchDB about this? > How is this different from document update handlers? Update handlers must be called by the client to be used. Auto update=20 functions would be called even if the client directly POST/PUT a doc to=20 the DB (so they would be mandatory). At first sight a good idea, it seems to me that auto update functions=20 would cause problem during replication : the replicated doc might be=20 different from the original one. Franck