vespa icon indicating copy to clipboard operation
vespa copied to clipboard

query_latency container metrics should include all query protocol phases

Open jobergum opened this issue 1 year ago • 3 comments

Most search-related metrics are captured within a search chain by the StatisticsSearcher.. For example, the query_latency metric will only capture the first protocol phase of query execution, not the time it takes to fill the result (Unless a searcher which is @After StatisticsSearcher calls fill).

jobergum avatar Mar 13 '23 09:03 jobergum

I believe the container.handled.latency metric with the appropriate handler tag would give you what you want here.

yngveaasheim avatar Mar 13 '23 11:03 yngveaasheim

Agree with @yngveaasheim. The Searcher API is a too high-level abstraction to observe the complete latency. This is not possible with today's Searcher API, and even the low level async RequestHandler API cannot do that. We need move query_latency out of the StatisticsSearcher and reimplement at our Jetty integration layer to report the full request latency (same as the duration in the access log).

bjorncs avatar May 15 '23 13:05 bjorncs

Resetting priority. This is part of larger effort to evaluate all existing container metrics.

bjorncs avatar Jun 27 '23 13:06 bjorncs