Docs » Splunk APMでスパンタグとMetricSetsを使ってサービスを分析する » カスタムディメンションを使用してMonitoring MetricSetsを生成する

カスタムディメンションを使用してMonitoring MetricSetsを生成する 🔗

Generate Monitoring MetricSets (MMS) with custom dimensions to monitor your services in real time. Splunk APM provides a default set of MMS, but you can configure additional MMS using indexed span tags to create custom dimensions. Use your custom MMS to create custom charts, dashboards, and detectors to track what matters most to your team. See カスタムディメンションのチャート、ダッシュボード、アラートの設定.

MetricSetsとは 🔗

MetricSets are metric time series (MTS) you can use to track the performance of specific metrics over time. To help you analyze your service performance, APM provides 2 categories of MetricSets: Troubleshooting MetricSets (TMS) and Monitoring MetricSets (MMS). Use Troubleshooting MetricSets for high-cardinality troubleshooting. Use Monitoring MetricSets for real-time monitoring and alerting.

APM provides a collection of MetricSets by default. You can also index additional span tags or processes to generate additional TMS and, as part of the indexing process, you can opt to create custom dimensionalized Monitoring MetricSets (MMS). See APMのMetricSetsについて for an overview of the types of MetricSets in APM and a list of the MetricSets available by default.

Use this topic to learn how to index a span tag or process to generate Monitoring MetricSets. See スパンタグをインデックス化してTroubleshooting MetricSetsを生成する to learn how to generate Troubleshooting MetricSets.

前提条件 🔗

Use custom Monitoring MetricSets to monitor important metrics 🔗

In addition to the MMS APM generates by default, you can create additional MMS with custom dimensions to filter and aggregate the default generated metrics by a specific indexed span tag or process such as version or cloud.provider.

You can create custom MMS at the service level and the endpoint or span level. When you create a custom dimension for a service-level MMS, APM generates an MMS that includes the service-level metrics with your chosen indexed span tag or process as a custom dimension. If you add endpoint-level metrics, APM generates MMS that include span-level metrics, with your chosen indexed span tag or process as a custom dimension.

When you create an MMS with a custom dimension, you can use the custom dimension to create charts, dashboards, and alerts. See カスタムディメンションのチャート、ダッシュボード、アラートの設定.

カスタムMMSの具体的なシナリオについては、シナリオ:Kaiが、ある顧客グループ向けのサービスのレイテンシのディテクターを監視する を参照してください。

カスタムディメンションを使用してMonitoring MetricSetsを生成する 🔗

MMSを作成する前に、まず以下を検討してください:

Monitoring MetricSetsの必要な構成方法を選択する 🔗

You can generate a Monitoring MetricSet in 3 ways:

  • サービスレベルのMMSのみ

  • 特定のサービス内の特定のエンドポイントに対するエンドポイントレベルのMMS

  • サービス内のすべてのエンドポイントに対して、サービスレベルのMMSとエンドポイントレベルのMMSの両方を適応させる

Select the best option for your needs to allocate your organization’s cardinality entitlement efficiently. See Configure your MMS to be more efficient to learn more.

You can also filter by specific tag values to further reduce the cardinality of your MMS.

オプション

ガイダンス

サービスレベルMMSとサービス内のすべてのエンドポイントのエンドポイントレベルMMS

このオプションは、選択した各サービスのカスタムディメンションMMSと、選択した各サービスの各エンドポイントのMMSを作成します。これは最もカーディナリティが高いオプションです。

サービスレベルMMSと特定のエンドポイントのエンドポイントレベルMMS

This option creates a custom dimensionalized MMS for each selected service and an MMS for specific endpoints you select. In the box labeled Endpoint Filters, provide a list of endpoints or a regular expression pattern to generate MMS for specific endpoints you’re interested in. This helps you to minimize unnecessary cardinality`.

サービスレベルのMMSのみ

このオプションは、選択した各サービスのMMSを作成し、エンドポイントレベルのMMSは作成しません。これは最もカーディナリティが低いオプションです。

Monitoring MetricSetsのスコープ 🔗

カスタムMMSは、エンドポイント( span* で始まるメトリクス)に対しても、サービス( service.request.* で始まるメトリクス)に対しても作成できますが、現時点では、ワークフロー( workflow* で始まるメトリクス)またはトレース( trace* で始まるメトリクス)に対しては作成できません。カスタムMMSは、グローバルタグには対応していません。

Monitoring MetricSetを追加する 🔗

以下の手順に従って、Monitoring MetricSetsを作成します。

  1. APM MetricSets ページには、以下のいずれかの方法で移動します:

    1. Splunk APMで、APM Configuration を選択し、メニューから APM MetricSets を選択する。APM MetricSetsページが開きます。

    2. Splunk Observability Cloudの任意の場所から、ナビゲーションバーで Settings を選択し、Data Configuration の下にある APM MetricSets を選択する。

  2. On the APM MetricSets page, you have 2 options:

    • スパンタグまたはプロセスを既にインデックス化している場合、そのスパンタグはMetricSetsのリストに表示され、既にTroubleshooting MetricSetsを生成しています。そのスパンタグの編集アイコンを選択して、Edit MetricSet ダイアログボックスを開き、以下の手順でMonitoring MetricSetを構成に追加します。

    • タグまたはプロセスをまだインデックス化していない場合は、新規MetricSet を選択します。インデックス化したいスパンタグまたはプロセスの 名前 を入力します。次に、以下の手順で続行します。

  3. スコープ は、APMがスパンタグやプロセスをトレース内のサービスとどのように関連付けるかを決定します。Service フィールドに、Monitoring MetricSetを作成するサービス(1つまたは複数)を入力します。カスタムディメンションMMSは、サービスレベルのインデックス付きスパンタグに対してのみ作成できます。グローバルにインデックス化されたスパンタグに対してカスタムMMSを作成することはできません。

  4. Add MetricSet または Edit MetricSet ダイアログボックスで、Monitoring MetricSetも作成する のチェックボックスにチェックを入れます。

  5. ドロップダウンから、タグまたはプロセスのデータをMonitoring MetricSetに追加する方法を選択します。詳細は Monitoring MetricSetsの必要な構成方法を選択する を参照してください。
    1. Service and all endpoint MMS: 選択した各サービスのMMSと、選択した各サービスの各エンドポイントのMMSを作成します。

    2. Service and specific endpoint MMS: Create an MMS for each selected service and an MMS for specific endpoints you select. To add Endpoint Filters, provide a list of endpoints or a regular expression pattern to generate MMS for specific endpoints you’re interested in.

    3. Service MMS only: 選択した各サービスのMMSを作成し、エンドポイントレベルのMMSは作成しません。

  6. (オプション) Filter by tag values というラベルの付いたフィールドで、タグフィルターを追加して、入力したタグ値に関連するデータのみを含むようにMMSの範囲を絞り込みます。これにより、MetricSetsのカーディナリティをさらに減らすことができます。

  7. 分析の開始 を選択して設定を送信します。Splunk APMがスパンタグまたはプロセスの分析を実行し、このMetricSetの潜在的なカーディナリティ寄与度を計算し、それがエンタイトルメントの制限内におさまるどうかを判断します。

  8. カーディナリティチェックの実行中、作成したメトリクスセットは、テーブルの 保留中のMetricSets セクションに、Analyzing ステータスで表示されます。チェックが実行されるまで、しばらく待つ必要があるかもしれません。

    注意

    Your pending MetricSet expires after 1 hour. If your MetricSet times out before you activate it, run the analysis again.

  9. After the cardinality check has run, review the cardinality and activate your new MetricSet.

以下は、カーディナリティチェックの例を示すものです。

この画像は、Monitoring MetricSetのカーディナリティチェックを示しています。

注釈

Splunk APMでは、MMS時系列のディメンション名のドットをアンダースコアに置き換えました。

インデックス付きスパンタグおよびプロセスのカーディナリティ寄与度 🔗

When you index a new span tag or process to generate Monitoring MetricSets, Splunk APM runs a cardinality contribution analysis to calculate the potential total cardinality contribution after indexing the span tag or process. This gives you control of what you index and helps you to account for organization subscription limits.

カーディナリティ寄与度の合計が制限を超えて増加する可能性のあるスパンタグやプロセスをインデックス化しようとする場合、インデックス化されたスパンタグやプロセスを修正または削除す ることで、インデックス化されたタグやプロセスの既存のカーディナリティ寄与度を変更することができます。

To see your TMS subscription limit, go to Settings then Subscription Usage. Depending on your organization subscription, you might need to go to Settings then Billing and Usage. Select the APM tab and then select the Troubleshooting MetricSets panel to view your subscription limit for MMS. You must have an admin or usage role to view subscription limits. To learn more about APM usage and billing, see Monitor Splunk APM billing and subscription usage.

カスタムディメンションのチャート、ダッシュボード、アラートの設定 🔗

You can create charts, dashboards, and alerts based on your custom Monitoring MetricSet.

To use the custom dimensionalized Monitoring MetricSets you have created, apply the filter sf_dimensionalized:true. This filters out the metrics generated by the default Monitoring Metricset. To filter your metrics even more, use the new dimension you have created which is the tag name you indexed.

タスク

ドキュメント

チャートの作成

Splunk Observability Cloudでチャートを作成する

ダッシュボードの作成

ダッシュボードの作成およびカスタマイズ

アラートの作成

Splunk APMでディテクターとアラートを設定する

APMダッシュボードでのサービスの監視

Splunk APMのダッシュボードを使用してサービスパフォーマンスを追跡する

Monitoring MetricSetsのメトリクスとディメンション 🔗

各MMSには、サービスパフォーマンスの監視とアラートに使用できる、スパンとトレースのメトリクスとディメンションのセットがあります。

To prevent over counting metrics in aggregations, the built-in dashboards and charts in Splunk APM automatically exclude custom dimensionalized MMS. Custom dimensionalized MMS have a marker dimension, sf_dimensionalized: true, to include custom dimensionalized MMS.

ダッシュボードやチャートを作成する際、!sf_dimensionalized: true でフィルターを追加することで、カスタムディメンションMMSを除外することができます。カスタムディメンションMMSの時系列をチャートで見たい場合は、sf_dimensionalized: true でフィルタリングしてから、表示したいカスタムディメンションで集計します。

This page was last updated on 2024年06月13日.