Amrit Sarkar created SOLR-18572:
-----------------------------------

             Summary: Query Insights module: per-node top-N queries and node API
                 Key: SOLR-18572
                 URL: https://issues.apache.org/jira/browse/SOLR-18572
             Project: Solr
          Issue Type: Sub-task
          Components: v2 API, metrics
            Reporter: Amrit Sarkar


Adds {{solr/modules/query-insights}}, registered through the SOLR-11994 hook.

*Scope*
* {{QueryInsightsLoader}} in core: loads the module only when 
{{solr.queryinsights.enabled=true}}; logs an error and keeps the node up if the 
module is missing or fails to init.
* {{TopQueriesRecorder}} per metric (latency, CPU): clock-aligned windows, 
current + previous, threshold check without a lock for requests that don't make 
the list.
* Record builder: params formatting, {{params.hidden}} redaction, 8 KB cap, 
trace id, costly features used.
* {{GET /api/node/query-insights/top-queries?type=latency|cpu}} for the local 
node, interface and model in {{solr/api}} so SolrJ gets a client. 
{{metrics-read}} permission.
* Settings from system properties only (cluster properties come in sub-task 4).

*Tests*: recorder (top-N, threshold, window alignment, rotation, 8 concurrent 
writers), record builder (redaction, truncation), settings validation, 
single-node API test, auth test, off-by-default test (404, no listeners).



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to