Reputation: 27
I was hoping to heavily use ArangoDB's query caching mechanism but then I read in the documentation "Queries that use the DOCUMENT() function cannot be cached" docs DOCUMENT(). Isn't the DOCUMENT function deterministic? What would be the reason to not cache?
I know that for one-to-one relations I could use FIRST(FOR ... FILTER _key = ...) but my understanding is the DOCUMENT() function is the fastest way to lookup another single document by _key and I don't want to have to compromise on querying efficiency and ease of use.
I also don't understand why a query can only be cached if "no warnings were produced while executing the query" Query Eligibility. That means that my query may cache most of the time but won't if it divides by 0, which seems so unrelated.
Upvotes: 0
Views: 11