Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 70351 invoked from network); 29 Apr 2010 16:22:00 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 29 Apr 2010 16:22:00 -0000 Received: (qmail 55500 invoked by uid 500); 29 Apr 2010 16:21:59 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 55453 invoked by uid 500); 29 Apr 2010 16:21:59 -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 55445 invoked by uid 99); 29 Apr 2010 16:21:59 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Apr 2010 16:21:59 +0000 X-ASF-Spam-Status: No, hits=1.9 required=10.0 tests=AWL,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_NEUTRAL,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: local policy) Received: from [209.85.217.220] (HELO mail-gx0-f220.google.com) (209.85.217.220) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Apr 2010 16:21:53 +0000 Received: by gxk20 with SMTP id 20so6583639gxk.12 for ; Thu, 29 Apr 2010 09:21:32 -0700 (PDT) MIME-Version: 1.0 Received: by 10.224.66.23 with SMTP id l23mr2817663qai.346.1272558091871; Thu, 29 Apr 2010 09:21:31 -0700 (PDT) Received: by 10.231.38.194 with HTTP; Thu, 29 Apr 2010 09:21:31 -0700 (PDT) In-Reply-To: References: <283E8E56-43DE-4058-803F-18FFC70A8127@gmail.com> Date: Thu, 29 Apr 2010 12:21:31 -0400 Message-ID: Subject: Re: adding the ability to do a POST to _changes From: Jarrod Roberson To: user@couchdb.apache.org Content-Type: multipart/alternative; boundary=00c09f89962c05a752048562856b --00c09f89962c05a752048562856b Content-Type: text/plain; charset=ISO-8859-1 On Thu, Apr 29, 2010 at 12:20 PM, Jarrod Roberson wrote: > my debug.js filter that just logged the contents of the request is working. > but anything that actually tries to return true/false just hangs with a > partially serialzied results > > function(doc, req) { var ids = JSON.parse(req.body); log(toJSON(ids)); var result = false; for (var i = 0; i < ids.length; i++) { log(ids[i]); if (ids[i] == doc._id) { result = true; break; } } return result; } > curl -X POST http://localhost:5984/mydb/_changes?filter=transfer/by_ids -d > ' > ["123","job_id:1234567890"]' > {"results":[ > -- Jarrod Roberson 678.551.2852 --00c09f89962c05a752048562856b--