Re:Crate: Distributed SQL Database for the Age of Docker
by naiv on Monday April 06, 2015 @05:02PM
(#9330679)
do you have a field type that indexes in real time? or are you bound to the (default 1s) index delay from es?
this is one thing that bothers me with elasticsearch, that I can not define eg "type": "cart","index":"realtime", "not-analyzed" so if an item gets added to a cart, the subsequent count would directly return the correct number of items in the cart.
Re:Crate: Distributed SQL Database for the Age of Docker
by jodok on Monday April 06, 2015 @06:02PM
(#9330950)
not yet. but we have some "tweaks" for exactly your use-case on our backlog. using the client libraries should make it mucn easier (e.g. https://crate.io/docs/projects/crate-python/stable/sqlalchem...). so right now you would need to do a refresh.
on a side note: it's not an index delay. it's the readers that "sit" on the lucene index. they are being repurposed for performance reasons (and meanwhile other writes are appending). like the client libraries you can force reopening them (https://crate.io/docs/en/0.47.8/sql/reference/refresh.html) - of course at the cost of performance.
Re:Crate: Distributed SQL Database for the Age of Docker
by ddorian43 on Monday April 06, 2015 @04:19PM
(#9330487)
Why can't you aggregate on non-indexed fields? I know lucene doesn't allow that, but why? It seems to work on normal-rdbms ?
Re:Crate: Distributed SQL Database for the Age of Docker
by jodok on Monday April 06, 2015 @06:13PM
(#9330996)
We run aggregations fully distributed and when iterating over the values we heavily rely on the field-caches. They hold the values of the latest used fields in memory and therefor allow in-memory performance on them. for example they don't grow linearly with the amount of rows stored, but depend on the cardinality of the fields. Running aggregations over non-indexed data is not supported.
If you'd like we're happy to answer any questions in IRC or our Google Group: https://groups.google.com/forum/#!forum/crateio IRC Freenode #crate: irc://irc.freenode.net/crate @mention anyone with Voice