Additional information for when runs are retained.#14362
Additional information for when runs are retained.#14362arkoppan wants to merge 3 commits intoMicrosoftDocs:mainfrom
Conversation
Clarified retention policy for Azure Repos regarding the latest runs retained for default and protected branches (only successful or partially succeeded runs are retained).
Clarified the retention policy for pipeline runs, specifying conditions under which runs are retained based on deployment success.
Only successful or partially succeeded runs are retained. Clarified the calculation for retention days based on run completion time.
|
@arkoppan : Thanks for your contribution! The author(s) and reviewer(s) have been notified to review your proposed change. |
| | Run 1 | main | Not retained | Neither latest 3 for main, nor for pipeline | | ||
|
|
||
|
|
||
| Further, the number of days to retain is calculated from when the run is completed. For example, there are two runs on a master branch on Jan 19th. The run that completed later is retained. |
There was a problem hiding this comment.
| Further, the number of days to retain is calculated from when the run is completed. For example, there are two runs on a master branch on Jan 19th. The run that completed later is retained. | |
| Further, the number of days to retain is calculated from when the run is completed. For example, there are two runs on a main branch on Jan 19th. The run that completed later is retained. |
|
Can you review the proposed changes? IMPORTANT: When the changes are ready for publication, adding a #label:"aq-pr-triaged" |
There was a problem hiding this comment.
Pull request overview
Updates Azure Pipelines retention policy documentation to clarify which runs are kept under “recent runs” retention and how retention days are calculated relative to run completion time.
Changes:
- Adds clarification that only successful or partially succeeded runs are considered for “latest runs” retention (Azure Repos case).
- Adds explanation/example that retention days are calculated from run completion time, including an illustrative screenshot.
- Minor formatting adjustments in the retention policy instructions section.
| Only latest successful or partially succeeded pipeline runs are retained. If deployment to only specific environment or stage succeeded, the run is not retained. | ||
|
|
There was a problem hiding this comment.
This new sentence is not indented under the “- Azure Repos: …” list item, so it will render as a separate paragraph (and can interrupt the list). Indent it to be part of the Azure Repos bullet, and consider separating it into its own indented paragraph for readability.
| Only latest successful or partially succeeded pipeline runs are retained. If deployment to only specific environment or stage succeeded, the run is not retained. | |
| Only latest successful or partially succeeded pipeline runs are retained. If deployment to only specific environment or stage succeeded, the run is not retained. |
|
|
||
| - **Azure Repos:** Azure Pipelines retains the configured number of latest runs for the [pipeline's default branch](../process/pipeline-default-branch.md) and for each protected branch of the repository. A branch that has any branch policies configured is considered to be a protected branch. | ||
| - **Azure Repos:** Azure Pipelines retains the configured number of latest runs for the [pipeline's default branch](../process/pipeline-default-branch.md) and for each protected branch of the repository. A branch that has any branch policies configured is considered to be a protected branch. | ||
| Only latest successful or partially succeeded pipeline runs are retained. If deployment to only specific environment or stage succeeded, the run is not retained. |
There was a problem hiding this comment.
Grammar is unclear in “If deployment to only specific environment or stage succeeded…”. Please reword to something grammatically correct and unambiguous (for example, clarify whether you mean a partially successful multi-stage run vs. a fully successful run).
| Only latest successful or partially succeeded pipeline runs are retained. If deployment to only specific environment or stage succeeded, the run is not retained. | |
| Only pipeline runs whose overall result is **Successful** or **Partially succeeded** are retained. Runs where deployments succeed in only certain environments or stages, and the overall run result is not **Successful** or **Partially succeeded**, are not retained. |
| | Run 1 | main | Not retained | Neither latest 3 for main, nor for pipeline | | ||
|
|
||
|
|
||
| Further, the number of days to retain is calculated from when the run is completed. For example, there are two runs on a master branch on Jan 19th. The run that completed later is retained. |
There was a problem hiding this comment.
This example introduces “master branch”, which is inconsistent with the earlier main terminology and can be confusing. Consider using “default branch” (or main) consistently, and clarify the outcome in terms of the computed deletion time/date (rather than saying the run “is retained”, which can be read as a different retention rule).
| Further, the number of days to retain is calculated from when the run is completed. For example, there are two runs on a master branch on Jan 19th. The run that completed later is retained. | |
| Further, the number of days to retain is calculated from when the run is completed. For example, suppose there are two runs on the default branch (for example, `main`) on Jan 19th. The run that completed later will have a later deletion time because its retention period is counted from its completion time. |
|
|
||
| <img width="700" height="267" alt="Screenshot 2026-03-26 095010" src="https://github.com/user-attachments/assets/d43056cc-649b-40b5-a66a-3ad8252d5d22" /> | ||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
There was a problem hiding this comment.
The image is embedded via a GitHub user-attachments URL and uses non-descriptive alt text. Please move the screenshot into this doc’s media/ folder (as the rest of the page does) and reference it consistently (for example via the existing :::image pattern), with meaningful alt text describing what the screenshot shows.
| <img width="700" height="267" alt="Screenshot 2026-03-26 095010" src="https://github.com/user-attachments/assets/d43056cc-649b-40b5-a66a-3ad8252d5d22" /> | |
| :::image type="content" source="media/retention-run-completion-time.png" alt-text="Example of pipeline run retention where, for two runs on the same day, the run that completed later is retained."::: |
|
|
||
|
|
||
|
|
||
|
|
There was a problem hiding this comment.
There are multiple consecutive blank lines after the image. Please remove the extra empty lines to keep the Markdown tidy and avoid unexpected spacing in rendering.
|
|
||
|
|
There was a problem hiding this comment.
There are two blank lines here (with whitespace) inside the numbered list. This can break Markdown list rendering and introduces trailing whitespace; please remove the extra empty/space-only lines so the list terminates cleanly before the moniker block.
Only successful or partially succeeded runs are retained.
Clarified the calculation for retention days based on run completion time.