prometheus / prometheus/client_python
Support multiprocess mode without setting an environment variable
まだ誰も着手していません。
- 主要言語
- Python
- スター
- 4.4k
- フォーク
- 876
- 平均マージ
- 8日 4時間
- マージ済み PR(30日)
- 1
説明
This is essentially a duplicate of issue #701
The main problem for my use case is that it's impossible to separate multiple instances of collectors, even though it has a path field misleading you into thinking that you can
https://github.com/prometheus/client_python/blob/master/prometheus_client/multiprocess.py#L22
I am personally not sure about ways of fixing that, apart from just unifying the implementations and only supporting the multiprocess mode. Because running python as multiple processes is arguably a more popular way of doing things, Web servers, and async processing all pretty much run on multiprocessing and it has to be the largest chunk of software that wants to be instrumented.
And while mmapped files have overhead, it's not super big and python is not used for blazingly fast things in general, so IMO it's a reasonable tradeoff for the simplicity of maintaining a single mode of operation.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず issue #701 と、そこで参照されている multiprocess.py の実装を読みます。この issue では複数の Collector インスタンスを分離する難しさが説明されていますが、実装方法や受け入れ基準は定義されていません。そのため、完了と見なされる条件を特定する前に、意図された動作とスコープを明確にしてください。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python
- 領域
- observability
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 20/100