[BUG] APIM diagnostics App insights publish failed first time, when I publish run pipeline again and select publish all artifact publish is getting success, it will happen every time.
- 主要言語
- C#
- スター
- 448
- フォーク
- 247
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
### Release version
5.1.3
### Describe the bug
APIM diagnostics App insights publish failed first time, when I publish run pipeline again and select publish all artifact publish is getting success, it will happen every time without making any changes in QA config file and getting below error.
System.Net.Http.HttpRequestException: HTTP request to URI https://management.azure.com/subscriptions/***/resourceGroups/rg-test/providers/Microsoft.ApiManagement/service/ag-int-test/diagnostics/applicationinsights?api-version=2022-04-01-preview failed with status code 412. Content is '{"error":{"code":"PreconditionFailed","message":"Exception of type 'Microsoft.WindowsAzure.ApiManagement.Management.Core.Exceptions.PreconditionFailedException' was thrown.","details":null}}'.
### Expected behavior
without make any changes in QA config file, it should be published.
### Actual behavior
when I approve PR, publish pipeline will start trigger to dev env and it will get success. When I approve changes to QA it's getting failed.
when I run manual trigger and select publish all artifact, publish is getting success. I haven't done any changes in QA env config file before approving PR. I was already configured all loggers and diagnostics inside the QA config file.
Without manual pipeline trigger, changes to go to QA env's.
### Reproduction Steps
Rename App insight name and add newly modified App insight in APIM logger and update it into named values and also update modified appinsights name into QA config file.
コントリビューションガイド
調査の方向性
まず、QA への変更を承認する際に使用される APIM diagnostics と Application Insights の発行経路を追跡し、HTTP 412 を返す management.azure.com リクエストに注目します。最初の発行と、成功した手動の「publish all artifact」実行を比較し、関連する QA 構成を調査します。構成を変更せずに、最初のパイプライン実行で QA の発行が成功すれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- azure, csharp
- 領域
- api, cloud, devops
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 25/100