Page MenuHomePhabricator

Label has-weighted-tag queries for scoped latency metric
Closed, ResolvedPublic3 Estimated Story Points

Description

As part of our commitment to Derived Data, we want to provide an SLO for search latency. We are specifically interested in queries for articles with suggestions, in other words, queries for weighted tags. Hence, if we could label such queries, we could write a focused grafana/prometheus query for this dimension.

Event Timeline

I think we need some work on Discovery-Search side to label queries before Data-Platform-SRE can start helping. Ping us when you need us!

Change #1330612 had a related patch set uploaded (by Peter Fischer; author: Peter Fischer):

[mediawiki/extensions/CirrusSearch@master] Add metric dimensions for weighted tags constraints

https://gerrit.wikimedia.org/r/1330612

As suggested today, I looked into Searcher::getPoolCounterType() as an alternative source for a label. The hypothesis is: If we measure latency only for simple queries [including weighted tags], we already have a metric to back the SLO. Here's a notebook to test it, which extracted the following for September 1st (mw_* is the full round trip time including processing in CirrusSearch, es_* is time spend by OpenSearch):

poolrequestsmw_p50mw_p95mw_p99es_p50es_p95
CirrusSearch-Search119834154525040517212
CirrusSearch-MoreLike10290931786161034174611
CirrusSearch-Prefix785752813731223130
CirrusSearch-Automated7503534685130229666
CirrusSearch-ExpensiveFullText374501311661167211231654
CirrusSearch-Semantic7414723723362687
poolweighted_tagsrequestsmw_p50mw_p95mw_p99es_p50es_p95
CirrusSearch-Searchfalse115589344825340918215
CirrusSearch-MoreLikefalse10292101786161032174611
CirrusSearch-Searchtrue426772645102339
CirrusSearch-Prefixfalse786322813730922128
CirrusSearch-Automatedfalse7514234683128929663
CirrusSearch-ExpensiveFullTextfalse329721612148172611502140
CirrusSearch-ExpensiveFullTexttrue457041851443578
CirrusSearch-Semanticfalse7437723723350687

Change #1330612 merged by jenkins-bot:

[mediawiki/extensions/CirrusSearch@master] Add metric dimensions for weighted tags constraints

https://gerrit.wikimedia.org/r/1330612