feat: add component-level publish channel configuration#107
Merged
reubeno merged 2 commits intomicrosoft:mainfrom Apr 24, 2026
Merged
feat: add component-level publish channel configuration#107reubeno merged 2 commits intomicrosoft:mainfrom
reubeno merged 2 commits intomicrosoft:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds component-level publish channel configuration to azldev so SRPM, RPM, and debuginfo routing can be controlled per component (with project and group defaults), and wires the resolved channels into component build output and package list.
Changes:
- Introduces
ComponentPublishConfig+default-component-configto support project → component-group → component publish defaults. - Renames package publish field to
rpm-channeland addsdebuginfo-channel; updates resolution codepaths to useResolve*PublishChannel. - Adds validation to prevent inheriting publish settings from multiple component groups, and updates schema/docs/snapshots accordingly.
Reviewed changes
Copilot reviewed 20 out of 20 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| schemas/azldev.schema.json | Updates config schema for new component publish fields and renamed package publish keys. |
| scenario/snapshots/TestSnapshots_config_generate-schema_stdout_1.snap | Snapshot update for schema generation output. |
| scenario/snapshots/TestSnapshotsContainer_config_generate-schema_stdout_1.snap | Snapshot update for schema generation output (container scenario). |
| internal/projectconfig/project.go | Adds DefaultComponentConfig and validates component-group publish ambiguity. |
| internal/projectconfig/project_test.go | Unit tests for component publish group membership validation. |
| internal/projectconfig/configfile.go | Adds default-component-config to config file model. |
| internal/projectconfig/loader.go | Merges default-component-config during config load/merge. |
| internal/projectconfig/component.go | Adds component publish config + resolution helpers for component/SRPM/package publish channels. |
| internal/projectconfig/package.go | Renames package publish channel to RPMChannel and adds DebugInfoChannel; simplifies ResolvePackageConfig. |
| internal/projectconfig/package_test.go | Updates tests for renamed package publish field / changed resolution order. |
| internal/projectconfig/loader_test.go | Updates config loading tests for renamed package publish keys and removed component default package config. |
| internal/projectconfig/fingerprint_test.go | Excludes ComponentConfig.Publish from fingerprinting (routing-only). |
| internal/app/azldev/cmds/pkg/list.go | Uses resolved publish channel helper when listing packages. |
| internal/app/azldev/cmds/pkg/list_test.go | Updates tests to match renamed package publish field. |
| internal/app/azldev/cmds/component/build.go | Adds SRPM publish channel to build results and resolves per-RPM publish channels via new helper. |
| docs/user/reference/config/project.md | Updates examples for renamed package publish key. |
| docs/user/reference/config/package-groups.md | Documents rpm-channel/debuginfo-channel and updates resolution order/examples. |
| docs/user/reference/config/components.md | Removes component default-package-config docs; adds component publish docs/examples. |
| docs/user/how-to/inspect-package-config.md | Updates layer count/resolution description after removing component default package config. |
reubeno
reviewed
Apr 20, 2026
f9ba4f2 to
50f9439
Compare
50f9439 to
295bee8
Compare
295bee8 to
07e6484
Compare
07e6484 to
445a8d2
Compare
Add ComponentPublishConfig to ComponentConfig for routing RPM, SRPM, and debuginfo packages to different publish channels. Key changes: - Add ComponentPublishConfig with rpm-channel, srpm-channel, debuginfo-channel fields - Add project-level DefaultComponentConfig (lowest-priority config layer) - Updated ResolveComponentConfig: project defaults → distro defaults → group defaults (sorted) → component explicit config - Implement ResolvePackagePublishChannel: selects channel from resolved component config, with package-group and per-package overrides - Add IsDebugInfoPackage helper using hyphen-delimited segment matching - Expose publish channel in 'azldev package list' output - Update docs: project.md (new default-component-config section), components.md, component-groups.md, package-groups.md, config-system.md, and how-to guides
0fdf9f3 to
fa9fd09
Compare
reubeno
reviewed
Apr 24, 2026
fa9fd09 to
ec96ded
Compare
…back Instead of migrating the deprecated 'publish.channel' TOML field to 'publish.rpm-channel' at load time, preserve the raw value and resolve it lazily via PackagePublishConfig.EffectiveRPMChannel(). This removes the migrateDeprecatedFields infrastructure entirely and keeps the backwards-compat logic close to where it is used. - Add EffectiveRPMChannel() value method: returns RPMChannel if set, falls back to DeprecatedChannel - Update packagePublishChannel() and synthesizeDebugPackages to call EffectiveRPMChannel() instead of reading RPMChannel directly - Remove migrateDeprecatedFields, migrateDefaultPackagePublishConfig, migratePackagePublishConfig functions and their log/slog import - Remove migrateDeprecatedFields() call from loader.go - Update four loader tests to assert that DeprecatedChannel is preserved as-is and EffectiveRPMChannel() returns the expected value - Fix DeprecatedChannel jsonschema description (remove stale 'Migrated automatically' wording) - Update docs: resolution order is distro → project → group → component - Regenerate schema snapshots
ec96ded to
ddab0fd
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add
ComponentPublishConfigtoComponentConfigfor routing RPM, SRPM, anddebuginfo packages to different publish channels and add backwards-compat support for deprecated 'publish.channel' TOML field.
Key changes:
ComponentPublishConfigwithrpm-channel,srpm-channel,debuginfo-channelfieldsDefaultComponentConfigResolveComponentConfig: distro defaults → project defaults → groupdefaults (sorted) → component explicit config
ResolvePackagePublishChannel: selects channel from resolved componentconfig, with package-group and per-package overrides
IsDebugInfoPackagehelper using hyphen-delimited segment matchingazldev package listoutputEffectiveRPMChannel()value method: returns RPMChannel if set, falls back to DeprecatedChannelcomponent-groups.md, package-groups.md, config-system.md, and how-to guides"
Example output with
components-publish.toml: