Track /bulk-lookup query times in /status, e.g. as recent_bulk_queries
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 35/100
- issue の種類
- 機能追加
- 明瞭さ
- 説明が足りない
- 活発さ
- 活発
- 技術スタック
- kubernetes, python
- 領域
- api, backend, observability
調査の方向性
Read api/server.py, especially lookup() and RecentLookups, and the recent_queries section of documentation/API.md; compare the existing /lookup tracking with bulk_lookup(). The issue leaves the entry unit, reported metrics, warning thresholds, and tracker design open. Done means those choices are settled and /status provides useful bulk latency and failure visibility without distorting /lookup statistics or adding undue probe cost.
索引モデルが issue の本文から書いたものです。
説明
/status's recent_queries times /lookup only. #231 deliberately leaves /bulk-lookup out: bulk_lookup() calls lookup(..., bulk=True) for each string, and those calls are neither recorded in the window nor logged as SLOW QUERY warnings. That keeps recent_queries meaning what its docs say. A single bulk request can hold thousands of strings, enough to swamp a 50000-entry window, and its strings compete with each other for Solr in a way a /lookup caller's doesn't, which would skew the percentiles. (See the bulk parameter's docstring on lookup() in api/server.py, and the recent_queries section of documentation/API.md.)
That leaves no latency or failure visibility for bulk traffic beyond the one Bulk lookup query for N strings ... took Xms INFO line per request. Bulk is the path NER pipelines use, so it is likely where most Solr load comes from.
One option is a separate tracker, e.g. recent_bulk_queries alongside recent_queries in /status. Questions to settle:
- What is one entry: a request or a string? Per request is closest to what a caller sees, but the times are only comparable after normalising by string count. Per string is comparable with
recent_queries, but needs a window sized differently, or one bulk request still dominates it. - What to report. Candidates: requests, strings per request, end-to-end time per request, per-string mean and p99 Solr wait, time spent waiting on the
SOLR_MAX_CONCURRENT_LOOKUPSsemaphore (whichlookup()'s own timer doesn't include), anderrors/timeouts/cancelledas inrecent_queries. - Logging. Should a slow bulk request (by some per-string or total threshold) get its own WARNING, instead of the per-string
SLOW QUERYlines that were dropped? - Cost.
/statusis what the Kubernetes probes call.RecentLookupsinapi/server.pykeeps running totals and caches percentiles for this reason, and a second tracker should do the same, or reuse that class.
Related: #286 (query-rate windows for recent_queries).
- 主要言語
- Python
- スター
- 5
- フォーク
- 4
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
NCATSTranslator/NameResolution のほかの issue
-
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
-
難易度 4/5 3〜5日 初心者へのやさしさ 43/100
-
難易度 3/5 1〜2日 初心者へのやさしさ 66/100
-
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
-
難易度 4/5 3〜5日 初心者へのやさしさ 45/100
NCATSTranslator/NameResolution の issue をすべて見る
似ている issue
-
cognition facet:consolidation memory ready size:S
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
proposal
難易度 1/5 1時間未満 初心者へのやさしさ 68/100
j3ko/agent-plugins#29 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 80/100
-
area:cli area:security bug priority:medium
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 74/100
Gathin23/cleanyourtv#4026 ·
メンテナーはふだん 1 日以内に返信