couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From J Chris Anderson <jch...@gmail.com>
Subject Re: adding the ability to do a POST to _changes
Date Thu, 29 Apr 2010 06:14:03 GMT

On Apr 28, 2010, at 11:07 PM, Jarrod Roberson wrote:

> On Thu, Apr 29, 2010 at 1:54 AM, J Chris Anderson <jchris@gmail.com> wrote:
> 
>> 
>> 
>> Your JavaScript function should be able to accept the POST body and use it
>> to decide whether to return true or false. So you can parse the JSON in your
>> _filter fun and return true or false based on a docid match.
>> 
>> 
> That is exactly what I came up with, but it seems a little expensive to
> parse that JSON over and over for every document that gets changed I figured
> it would be more efficient to do it in the Erlang layer once and be done
> with it.
> 

There are a million optimizations it'd be nice to have. As a project we are focussed on getting
the programming model solid and flexible enough. After 1.0 we'll focus on optimizations. 

There is a patch in 0.11 to allow for replication by docid. There should be a test case for
it, and a closed Jira issue. I haven't used it yet but I'm pretty sure I remember it being
applied.

Chris


> -- 
> Jarrod Roberson


Mime
View raw message