From user-return-13352-apmail-couchdb-user-archive=couchdb.apache.org@couchdb.apache.org Mon Oct 25 14:57:52 2010 Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 55082 invoked from network); 25 Oct 2010 14:57:50 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 25 Oct 2010 14:57:50 -0000 Received: (qmail 34821 invoked by uid 500); 25 Oct 2010 14:57:48 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 34755 invoked by uid 500); 25 Oct 2010 14:57:48 -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 34747 invoked by uid 99); 25 Oct 2010 14:57:47 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Oct 2010 14:57:47 +0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of adam.kocoloski@gmail.com designates 209.85.216.52 as permitted sender) Received: from [209.85.216.52] (HELO mail-qw0-f52.google.com) (209.85.216.52) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Oct 2010 14:57:38 +0000 Received: by qwh5 with SMTP id 5so1686280qwh.11 for ; Mon, 25 Oct 2010 07:57:17 -0700 (PDT) Received: by 10.229.65.25 with SMTP id g25mr6689661qci.196.1288018637415; Mon, 25 Oct 2010 07:57:17 -0700 (PDT) Received: from [10.1.10.164] (c-66-31-20-188.hsd1.ma.comcast.net [66.31.20.188]) by mx.google.com with ESMTPS id m7sm6126678qck.13.2010.10.25.07.57.13 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 25 Oct 2010 07:57:14 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Apple Message framework v1081) Subject: Re: Questions about changes feed From: Adam Kocoloski In-Reply-To: Date: Mon, 25 Oct 2010 10:57:12 -0400 Content-Transfer-Encoding: quoted-printable Message-Id: <7F47D1F3-9D05-4C7A-896D-8EA41D6B10F7@apache.org> References: To: user@couchdb.apache.org X-Mailer: Apple Mail (2.1081) X-Virus-Checked: Checked by ClamAV on apache.org On Oct 24, 2010, at 10:10 PM, kowsik wrote: > I have a few questions about the _changes feed. >=20 > 1. How many changes are kept around for each DB? Obviously, not > everything, but is it the last 100, 1000 or some other configurable > limit? The most recent edit of each branch of every document is kept around = forever, or until a new edit on that branch occurs. > 2. When I'm using a filter in a _design document, is the most recent > version of the _design document used for the filtering or does it > depend on the update seq? Let me elaborate: >=20 > seq #1 (added _design doc with filter v1) > seq #2 (doc A changed) > seq #3 (updated _design doc to v2) > seq #4 (doc B changed) >=20 > In the above case, when I invoke the _changes API, does it always use > the v2 filter for all changes or uses v1 for seq #2 and v2 for seq #4? If you submit the _changes request after #3 has been saved you'll use v2 = of the filter for all changes. I believe if you submit the request = before #3 is saved your entire request will be filtered using v1. > 3. If there were a 1000 changes and I invoke _changes without 'since', > does all filter get invoked with all of the pending changes? The filter that you specify will be invoked on all 1000 changes, yes. = Best, Adam