We're updating our terminology in Jira

'Issue' is changing to 'work item'. You might notice some inconsistencies while this big change takes place.

Microsoft Azure Event Hubs と統合する

この記事では、Jira Service Management Cloud の一部のお客様に段階的に展開されている、Jira Service Management でネイティブに利用できる新しいアラート機能を取り上げています。ご利用のサイトにはまだ表示されていないか、利用できない可能性があります。

Microsoft Azure Event Hubs のロゴ

メトリック値に関するアラート ルールの場合、指定されたメトリックの値が割り当てられたしきい値を超えると、アラート ルールがアクティブになり、通知が送信されます。イベントに関するアラート ルールの場合、ルールはすべてのイベントについて、または特定の数のイベントが発生した場合にのみ、通知を送信できます。

統合でできるようになること

Azure Event Hubs ではメトリックに基づいてアラートを生成できます。Jira Service Management は、Azure によって生成されたアラートのディスパッチャーとして機能します。Jira Service Management では、オンコール スケジュールとエスカレーションに基づいて通知すべきユーザーを決定し、メール、テキスト メッセージ (SMS)、電話、Android や iOS のプッシュ通知による通知を行います。

Jira Service Management では新しい Azure メトリック アラートもサポートされています。Azure の新しいメトリック アラートでは、新しい Azure ペイロードに新しいフィールドが追加されています。そのため、これらをサポートするように統合を設定できます。詳細については「Azure Monitor のメトリック アラートでサポートされているリソース - Azure Monitor」をご確認ください。

統合による機能

Azure Event Hubs でアラートが作成されると、統合を通じて Jira Service Management でアラートが自動的に作成されます。

統合をセットアップする

Azure Event Hubs は API ベースの統合です。設定は次の手順で行います。

  • Jira Service Management で Azure Event Hubs 統合を追加する

  • Azure Event Hubs で統合を設定する

Azure Event Hubs 統合を追加する

双方向統合は Free プランと Standard プランではサポートされていません。他のすべての統合は FreeStandard でチーム レベルでサポートされています。ただし、送信統合を機能させるには、上位のプランにアップグレードする必要があります。Settings (歯車アイコン) > Products (Jira 設定の下) > OPERATIONS からサイト レベルで統合を追加できるのは、Premium プランと Enterprise プランのみです。

統合をチームの運用ページから追加すると、そのチームが統合の所有者になります。つまり、Jira Service Management は、この統合を通じて受信したアラートをチームにのみ割り当てます。

Jira Service Management で Azure Event Hubs 統合を追加するには、次の手順を実行します。

  1. チームのオペレーション ページに移動します

  2. 左側のナビゲーション パネルで、[統合]、[統合を追加] の順に選択します。

  3. 検索を実行して「Azure Event Hubs」を選択します。

  4. 次の画面で、統合の名前を入力します。

  5. オプション: 特定のチームが統合からのアラートを受信するようにする場合は、[Assignee team (担当者チーム)] のチームを選択します。

  6. [Continue] を選択します。
    この時点で、統合が保存されます。

  7. [統合を設定する手順] セクションを展開して、ご利用のアカウント用に生成された統合 URL をコピーします。
    この URL は、後ほど Azure で統合を設定する際に使用します。

  8. [統合をオンにする] を選択します。
    統合のために作成したルールは、統合をオンにした場合にのみ機能します。

Azure Event Hubs で統合を設定する

Azure Event Hubs で統合を設定するには、次の手順を実行します。

  1. Azure ポータルで「Events Hubs」ページにアクセスします。

  2. アラートの追加先となるイベント ハブの名前スペースを参照します。

  3. [監視] セクションで [アラート] を選択します。

  4. [アクション グループ] タブに移動します。

  5. [作成] を選択して新しいアクション グループを作成します。
    アクションを追加する際は、アクション タイプに [Webhook] を選択します。

  6. さきほど Jira Service Management からコピーした統合 URL を [URI] に貼り付けます。

  7. 必要に応じて、共通のアラート スキーマを有効にします。

  8. 変更を保存します。

  9. [アラート ルール] タブに移動します。

  10. ルールを作成するか、既存のルールを編集します。

  11. アラートをフィルタリングするための条件を追加します。

  12. [アクション グループ] セクションで、ステップ 5 で作成した Webhook アクション グループを追加します。

  13. 変更を保存します。

Azure メトリック アラートから送信されたペイロードのサンプル

アラート ペイロード (JSON 形式) を作成する

{ "schemaId": "AzureMonitorMetricAlert", "data": { "version": "2.0", "properties": null, "status": "Activated", "context": { "timestamp": "2020-06-24T10:28:19.3462700Z", "id": "/subscriptions/25b83e19-ab0d-4579-ad81-asdas-sadasda/resourceGroups/test_eventhub_group/providers/microsoft.insights/metricalerts/test-eventhub-alerts", "name": "test-eventhub-alerts", "description": "test description for alert", "conditionType": "SingleResourceMultipleMetricCriteria", "severity": "3", "condition": { "windowSize": "PT1M", "allOf": [{ "metricName": "SuccessfulRequests", "metricNamespace": "Microsoft.EventHub/namespaces", "operator": "GreaterThan", "threshold": "2", "timeAggregation": "Total", "dimensions": [{ "name": "ResourceId", "value": "25b83e19-ab0d-4579-ad81-d0280e506bb3:test-eventhub-og" }, { "name": "EntityName", "value": "test-eventhub" }, { "name": "OperationResult", "value": "Success" }], "metricValue": 8.0, "webTestName": null }, { "metricName": "IncomingRequests", "metricNamespace": "Microsoft.EventHub/namespaces", "operator": "GreaterThan", "threshold": "3", "timeAggregation": "Total", "dimensions": [{ "name": "ResourceId", "value": "25b83e19-ab0d-4579-ad81-d0280e506bb3:test-eventhub-og" }, { "name": "EntityName", "value": "test-eventhub" }], "metricValue": 8.0, "webTestName": null }] }, "subscriptionId": "25b83e19-ab0d-4579-ad81-d0280e506bb3", "resourceGroupName": "test_eventhub_group", "resourceName": "test-eventhub-og", "resourceType": "Microsoft.EventHub/namespaces", "resourceId": "/subscriptions/25b83e19-ab0d-4579-ad81-d0280e506bb3/resourceGroups/test_eventhub_group/providers/Microsoft.EventHub/namespaces/test-eventhub-og", "portalLink": "https://portal.azure.com/#resource/subscriptions/25b83e19-ab0d-4579-ad81-d0280e506bb3/resourceGroups/test_eventhub_group/providers/Microsoft.EventHub/namespaces/test-eventhub-og" } } }

Azure 共通アラート スキーマから送信されたペイロードのサンプル

(JSON 形式)

{ "schemaId": "azureMonitorCommonAlertSchema", "data": { "essentials": { "alertId": "/subscriptions/25b83e19-ab0d-4579-ad81-d0280e506bb3/providers/Microsoft.AlertsManagement/alerts/7ccad036-8973-49e9-b628-a18350fb32bb", "alertRule": "test-eventhub-alerts", "severity": "Sev3", "signalType": "Metric", "monitorCondition": "Fired", "monitoringService": "Platform", "alertTargetIDs": ["/subscriptions/25b83e19-ab0d-4579-ad81-d0280e506bb3/resourcegroups/test_eventhub_group/providers/microsoft.eventhub/namespaces/test-eventhub-og"], "originAlertId": "25b83e19-ab0d-4579-ad81-d0280e506bb3_test_eventhub_group_microsoft.insights_metricalerts_test-eventhub-alerts_-121967519", "firedDateTime": "2020-06-29T18:41:05.7016722Z", "description": "", "essentialsVersion": "1.0", "alertContextVersion": "1.0" }, "alertContext": { "properties": null, "conditionType": "SingleResourceMultipleMetricCriteria", "condition": { "windowSize": "PT1M", "allOf": [{ "metricName": "SuccessfulRequests", "metricNamespace": "Microsoft.EventHub/namespaces", "operator": "GreaterThan", "threshold": "2", "timeAggregation": "Total", "dimensions": [{ "name": "ResourceId", "value": "25b83e19-ab0d-4579-ad81-d0280e506bb3:test-eventhub-og" }, { "name": "EntityName", "value": "test-eventhub" }, { "name": "OperationResult", "value": "Success" }], "metricValue": 4.0, "webTestName": null }], "windowStartTime": "2020-06-29T18:38:52.06Z", "windowEndTime": "2020-06-29T18:39:52.06Z" } } } }

 

さらにヘルプが必要ですか?

アトラシアン コミュニティをご利用ください。