Azure / Azure/azure-sdk-tools

.NET pipeline gaps in CI trigger settings

Open
#16,965 1 comment 0 reactions 1 assignee Claimed by @raych1 View on GitHub
Dominant language
C#
Stars
135
Forks
260
Avg merge
3d 1h
Merged PRs (30d)
143

Description

## Summary

CI triggers are not enabled for the .NET management-plane SDK pipelines. Nearly all `ci.mgmt.yml` files in `azure-sdk-for-net` are set to `trigger: none`, so merging a PR to `main` does not automatically queue the corresponding pipeline. This blocks automatic release pipeline runs on merge and requires manual pipeline queuing today.

## Impact

- Release pipelines are not triggered automatically when a PR merges to `main`.
- The same gap applies to the `hotfix/*` and `release/*` branches.
- Releases depend on manual intervention, which is slower and easy to miss.

## Proposal

Add a `trigger` block to each `ci.mgmt.yml`, scoped by path so that only relevant changes queue each pipeline:

```yaml
trigger:
branches:
include:
- main
- hotfix/*
- release/*
paths:
include:
- sdk/apicenter/Azure.ResourceManager.ApiCenter
```

## Implementation notes

A few details worth calling out for anyone picking this up, based on doing the pass across the repo:

- **246 `ci.mgmt.yml` files** are affected; all but `sdk/resourcemanager/ci.mgmt.yml` were `trigger: none`.
- **Path filters must cover every artifact the pipeline builds, not just `Azure.ResourceManager.*`.** Around 60 management pipelines also build an `Azure.Provisioning.*` package, and those packages are not built by the data-plane `ci.yml`. If their paths are omitted, changes to them would build and release nothing.
- **Several services build multiple packages** from one pipeline (for example `alertsmanagement` with 6, `resources` with 5, `monitor` and `kubernetesconfiguration` with 4 each). Each needs its own path entry.
- **Do not derive the path purely from the artifact `name`.** At least one artifact name does not match its directory casing: `sdk/redhatopenshift` declares `Azure.ResourceManager.RedHatOpenshift` while the directory on disk is `Azure.ResourceManager.RedHatOpenShift`. Azure Pipelines path filters are case-sensitive, so validate against the real directory rather than the declared name. Note that `Test-Path` on Windows is case-insensitive and will not catch this.

## Related

- Repo-wide pass for `azure-sdk-for-net`: Azure/azure-sdk-for-net#62806

## Follow-up

The scaffolding template at `eng/templates/Azure.ResourceManager.Template/content/ci.mgmt.yml` also needs the trigger block so newly onboarded management libraries get it by default. That change requires corresponding scaffolding script updates (the template uses `LowercaseProviderShortName` and `Azure.ResourceManager.Template` placeholders that must be substituted into the path filter), so it is intentionally excluded from the PR above and should be handled separately.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.