Question: how should a partially failed incremental publish be recovered when artifacts or overrides need correction?

未關閉
#347 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

評估

難度
4/5
預估耗時
3-5 天
新手友好度
48/100
Issue 類型
文件
描述清晰度
描述清楚
活躍度
活躍
技術堆疊
azure, typescript

研究方向

Read the incremental publish guide and the referenced first-parent selection and publish target logic in src/services/git-diff-service.ts and src/services/publish-service.ts. Determine whether the CLI supports combining corrected inputs with the original change and deletion set, including unchanged artifacts with corrected overrides. Document a safe recovery sequence or the limitation and manual procedure, with evidence required before advancing the successful deployment SHA.

由索引模型根據 Issue 內容生成。

描述

Question

What is the recommended recovery procedure when an incremental publish partially fails and resolving the cause requires changing an artifact or override configuration in a new commit?

The goal is to complete the original intended updates and deletions together with the correction, without deleting destination resources outside the repository's management scope.

Version under evaluation: @azure-tools/apiops-cli 1.0.4. This question is based on the documented selection semantics and source review. The following is a synthetic scenario, not a reproduced APIM incident.

Example scenario

Consider a linear history A -> B -> C:

Commit Intended repository state / changes Deployment status
A Baseline configuration Fully deployed
B Updates managed Policies P and Q, and deletes the artifact for managed Product R Publication attempted but only partially applied
C Corrects the invalid content of P; Q and R have no additional Git changes Not yet deployed

Assume the partial result of publishing B includes an unsuccessful update of Q and an unsuccessful deletion of R. Correcting P requires C, so an identical-input retry of B is not sufficient.

Based on the documented first-parent selection:

  • Publishing --commit-id <C_SHA> --delete-unmatched selects B-to-C, which does not include Q's original update or R's deletion.
  • Checking out B and retrying the original input still uses P's invalid content.
  • Checking out C while supplying B as --commit-id appears to mix one commit's change selection with another commit's file contents. We do not want to assume this is a supported recovery method.
  • Full publish without deletion does not complete R's deletion.
  • Full publish with deletion is unsuitable because the destination also contains resources outside the repository's management scope.
Requested guidance
  1. Is there a supported sequence for completing B's outstanding changes using corrected artifacts and overrides from C? Please identify the exact checkout, comparison, and input requirements.
  2. How should the sequence preserve the original deletion set and safely handle changes already applied during the first attempt?
  3. What evidence should the pipeline use before marking the recovered release successful and advancing its successful deployment SHA?
  4. If this cannot be expressed safely with the current CLI, could the limitation and a recommended manual recovery procedure be documented?

If the correction is in an override file rather than an artifact, please also explain how to ensure the corrected override is applied when the corresponding artifact is unchanged.

Context

Only part of the destination APIM configuration is managed by this repository. Recovery therefore cannot rely on unrestricted full destination reconciliation.

The question is not about resuming at the failed resource, automatic rollback, or rerunning the same SHA after fixing only an external condition. It specifically concerns a correction that changes the publish inputs and introduces a new commit.

A documented, repeatable procedure would help pipelines avoid treating a later successful but narrower incremental run as completion of an earlier partially failed release.

References and related issues

If a newer release already provides a supported recovery workflow, guidance for that version would also be useful.

主要語言
TypeScript
星號
44
分支
14
PR 合併指標
30 天內沒有已合併 PR

環境準備

在 Codespaces 中開啟

在瀏覽器裡用你自己的 GitHub 帳號啟動這個專案的開發容器。

  • 沒有 Dockerfile 或 Docker Compose 檔案
  • 沒有 Pull Request 範本
  • 閱讀貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

Azure/apiops-cli 的其他 Issue

查看 Azure/apiops-cli 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。