3 ms·
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 elasticsea
by naiv 12y ago
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.
- jodok 12y agonot 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/sqlalchemy.html#updating-complex-types 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 https://crate.io/docs/en/0.47.8/sql/reference/refresh.html) - of course at the cost of performance.