@neatcode from the Java SDK, there is currently no way to change the “stale” behavior for a N1QL query. This is something we will work through in the next months and for sure have a good solution once it ships together with the product.
For now you have to use the defaults that N1QL provide or fall back to Views.
@neatcode, we have the existing flags - stale=false|after|ok in views. would it suffice for you to have those or which one would be your choice? would you want another flavor in couchbase?
thanks
-cihan
thanks! would you be ok with a new level that would NOT update the indexes to the ‘time’ the was executed but to the ‘time’ that your last update happened on this connection? Essentially RYOW (read your own write)? if you have a few milliseconds between your last update and your query, this may reduce the latency of your query by quite a bit. would that be interesting in your case.
We are looking at new options and that is why I am poking at this. I’d appreciate your feedback.
thanks
-cihan