couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dale Harvey <d...@arandomurl.com>
Subject Re: [POC] Mango Catch All Selector
Date Mon, 04 Jan 2016 12:33:57 GMT
I havent yet started looking into the implementation details, but when
using pouchdb-find I have very much always expected that at some point we
would analyse the queries and automatically produce an index for them. This
seems like a great step in between.

On 4 January 2016 at 13:27, Robert Kowalski <rok@kowalski.gd> wrote:

> Hi list,
>
> I hope you had awesome holidays!
>
> The whole holidays I thought about an idea I had and today I
> implemented a prototype which still has some bugs and isn't complete
> yet.
>
> I want to find out if there is general interest and if it would be
> worth to spend more time.
>
> The problem I am trying to solve is that I usually have a hard time
> explaining people how views work. Now we got Mango and I can just say:
> we use a syntax similar to MongoDB's query language _but you have to
> create an index before you can use it_.
>
> At this point I usually look into sad, big eyes because no one
> understands why they have to create an index first and I feel there is
> another entry barrier for newcomers. If trying anyway given they have
> decided for CouchDB the user gets a error back: "no index available
> for this selector".
>
> The idea of this patch is to just fallback on the "give me all docs
> and i filter afterwards"-trick that people usually use (if they know
> it) when they just want to test something, without creating an index
> which can take time for creation and requires further knowledge.
> Additionally the user is warned that they can create an index to make
> the queries faster.
>
> What do you think? Is that something worth to work on further? The PR
> is at https://github.com/apache/couchdb-mango/pull/27
>
> You can test it with basic queries on a database which does not have
> indexes for the fields you want to query created yet.
>
>
> Best,
> Robert :)
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message