How to track query execution time in couchbase N1QL server?
Is there an easy way to get the query time on the couchbase N1QL server like .explain () in mongodb?
I have a type request SELECT c.name, c.description from customer c
and I would like to track the time.
in N1QL
, JSON responses and include metadata. the field metrics
contains statistics, including the time taken to execute the request (especially elapsedTime
and executionTime
).
in the 2.2.0 developer preview
Java SDK, you can access these metrics as an object QueryMetrics
using the method info()
on QueryResult
.