Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Can we change the configuration like sampling duration at runtime without restarting the app?

オープン
#131 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
java
領域
observability

調査の方向性

まず Config.Builder と PyroscopeAgent.start を確認し、特にサンプリング期間とプロファイリング設定がどのように保存され、適用されるかを調べます。エージェントが再起動なしで実行時の更新を公開できるかどうかを確認します。起動後にアプリを再起動せずにサンプリング期間またはサンプリングレートを変更でき、その動作が関連するテストでカバーされていれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Currently, we can provide the sampling duration at the time of building configuration and then we provide that configuration to PyroscopeAgent.start(config) method.

But i didn't find any method/api so that i can change the sampling duration/sampling rate after starting the agent without restarting the app.

Please let me know if we can achieve this behavior already and i have missed it or it is not possible for now with current code.

Thanks.

    PyroscopeAgent.start(
        new Config.Builder()
            .setApplicationName("app-java")
            .setProfilingEvent(EventType.ITIMER)
            .setFormat(Format.JFR)
            //pyroscope is service name
            // pyroscope-test is namespace in which pyroscope service is running and listening for profiling data
            .setServerAddress("http://pyroscope.pyroscope-test.cluster.local:4040")
            // Optionally, if authentication is enabled, specify the API key.
            // .setAuthToken(System.getenv("PYROSCOPE_AUTH_TOKEN"))
            // Optionally, if you'd like to sets allocation threshold to register events, in bytes. '0' registers all events
            // .setProfilingAlloc("0")
            .setSamplingDuration(Duration.ofSeconds(1))
            .build()
    );
主要言語
Java
スター
125
フォーク
48
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

grafana/pyroscope-java のほかの issue

grafana/pyroscope-java の issue をすべて見る

似ている issue

Java の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。