Return-Path: Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: (qmail 95768 invoked from network); 29 Nov 2009 03:54:45 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 29 Nov 2009 03:54:45 -0000 Received: (qmail 13344 invoked by uid 500); 29 Nov 2009 03:54:44 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 13157 invoked by uid 500); 29 Nov 2009 03:54:43 -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 13143 invoked by uid 99); 29 Nov 2009 03:54:43 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 29 Nov 2009 03:54:43 +0000 X-ASF-Spam-Status: No, hits=-10.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 29 Nov 2009 03:54:40 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 9E472234C052 for ; Sat, 28 Nov 2009 19:54:20 -0800 (PST) Message-ID: <1383409398.1259466860632.JavaMail.jira@brutus> Date: Sun, 29 Nov 2009 03:54:20 +0000 (UTC) From: "Roger Binns (JIRA)" To: dev@couchdb.apache.org Subject: [jira] Commented: (COUCHDB-582) _changes filter missing updates In-Reply-To: <1068011484.1259449460776.JavaMail.jira@brutus> 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-582?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783355#action_12783355 ] Roger Binns commented on COUCHDB-582: ------------------------------------- Not quite as good as tests, but here is an exact description of what they should do. Create a filter function: function(doc, req) { // log("filter "+toJSON(doc)); -- useful for debugging and confirming filter was even called return doc.type=="A" || doc._deleted; } Now watch _changes with that filter function. You should verify that there is always at least one row returned. Create several docs in a row with doc.type="A". Delete them. There should always be at least one row returned. (Bonus points for matching up returned rows with creation/deletion activity.) A related issue is that _changes requests return based on if there was data before filtering. Consequently running the above will return no rows if you create doc.type="B". It would be more efficient to only return if there are rows *after* filtering in which the above test can continue to run and should not return if you create doc.type="B". > _changes filter missing updates > ------------------------------- > > Key: COUCHDB-582 > URL: https://issues.apache.org/jira/browse/COUCHDB-582 > Project: CouchDB > Issue Type: Bug > Components: JavaScript View Server > Reporter: Chris Anderson > Assignee: Chris Anderson > Fix For: 0.11 > > > reported on the user mailing list: > http://mail-archives.apache.org/mod_mbox/couchdb-user/200911.mbox/%3c4B10BD2C.5070200@rogerbinns.com%3e > I know there is work to be done on the filter mechanism (specifically around process reuse and concurrency) > The current implementation requires a process per connected user. This should be not that hard to patch. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.