You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(autodiscovery): replace versionfilters with tracks - #11478
Autodiscovery "versionfilters" becomes "tracks", before it is released. Each track has a name and sets "versionfilter", "age" or both, so one crawler can, for example, take minor updates after 3 days and major updates after 14 days.
A track setting can't also be set on the crawler. Unknown track settings are rejected, and "age" is only accepted, and offered by the json schema, for crawlers supporting it. The generated pipelines are labelled with "updatecli.io/track" instead of "updatecli.io/versionfilter".
Fix #XXX
Test
To test this pull request, you can run the following commands:
cd<to_package_directory>
go test
Additional Information
Checklist
I have updated the documentation via pull request in website repository.
I have tested this pull request manually with a custom Updatecli build and it works as expected.
Tradeoff
Potential improvement
Summary by CodeRabbit
New Features
Autodiscovery now supports named tracks that combine version-filter and age settings, with tracks processed in rank order.
Track settings are validated against crawler capabilities, and age options are shown only for supported crawlers.
Generated pipeline labels and waiting messages identify the track.
Configuration
Define crawler variants with tracks and nest version-filter settings within each track.
Autodiscovery "versionfilters" becomes "tracks", before it is released.
Each track has a name and sets "versionfilter", "age" or both, so one
crawler can, for example, take minor updates after 3 days and major
updates after 14 days.
A track setting can't also be set on the crawler. Unknown track settings
are rejected, and "age" is only accepted, and offered by the json schema,
for crawlers supporting it. The generated pipelines are labelled with
"updatecli.io/track" instead of "updatecli.io/versionfilter".
Signed-off-by: Olblak <me@olblak.com>
Review was skipped as selected files did not have any reviewable changes.
Run configuration
Source mode: Auto
Repository: Unavailable
Branch: Unavailable
File: No configuration file from this repository applied
Commit: Unavailable
Layers: defaults
Review profile: CHILL
Plan: Advanced
Run ID: 93750c73-78f8-444d-b39b-eec8dce2ba7b
Commits
Reviewing files that changed from the base of the PR and between 9fe894c and 52995ae.
You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.
Use the checkbox below for a quick retry:
Trigger review
No actionable comments were generated in the recent review.
Walkthrough
Autodiscovery replaces named version filters with tracks. Tracks can contain version-filter or age settings. Expansion, validation, generated pipeline metadata, and gate ordering now use track names and ranks.
Changes: Autodiscovery tracks
Layer / File(s)
Summary
Track configuration and expansion pkg/core/pipeline/autodiscovery/variant.go, pkg/core/pipeline/autodiscovery/jsonschema.go, pkg/core/pipeline/autodiscovery/config.go, pkg/core/pipeline/autodiscovery/variant_test.go, pkg/core/pipeline/gate.go
The autodiscovery specification now accepts named tracks with version-filter or age settings. Expansion validates track names and settings, combines tracks with groups, and applies supported settings to crawler specs. Schemas expose age only for supported crawler kinds.
Generated pipeline IDs, labels, titles, and logs now identify tracks. The Dockerfile example defines minor and major tracks, each with a nested semver version filter.
Track ordering and waiting pkg/core/engine/gate.go, pkg/core/engine/gate_test.go, pkg/core/engine/order.go, pkg/core/engine/order_test.go, pkg/core/engine/run.go
The engine uses track names and ranks when checking whether a pipeline must wait and when ordering gated pipelines. Pending-update and lookup behavior remain unchanged.
updatecli/updatecli#11465: Adds the versionfilters setting and label that this PR replaces with tracks.
updatecli/updatecli#11470: Changes label filtering for generated pipelines, including autodiscovery labels used to select track pipelines.
updatecli/updatecli#11300: Defines age-filter behavior used by the age settings that tracks can carry.
Suggested reviewers:loispostula
Merge Risk: Minimal · previous review 9fe89
This change renames autodiscovery versionfilters to tracks and lets each track set a version filter, an age, or both. Generated pipelines use the updatecli.io/track label. No concrete defects were found in the reviewed changes, so the merge risk is minimal. The author should still run the package tests and finish the documentation and manual-testing checklist items.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title "feat(autodiscovery): replace versionfilters with tracks" matches the main change. The PR replaces the autodiscovery versionfilters configuration with tracks, which can set versionfilter, ag…
Description check
The description explains the purpose of the change. It states that versionfilters become tracks, that each track sets versionfilter, age, or both, and that track settings cannot also be set on the cra…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "feat(autodiscovery): replace versionfilters with tracks" matches the main change. The PR replaces the autodiscovery versionfilters configuration with tracks, which can set versionfilter, age, or both. The title is short, specific, and follows a conventional commit style.
Full details: Description check
Explanation
The description explains the purpose of the change. It states that versionfilters become tracks, that each track sets versionfilter, age, or both, and that track settings cannot also be set on the crawler. It also covers unknown-setting rejection, age support limits in the JSON schema, and the new updatecli.io/track label. The template sections are kept. The Fix #XXX placeholder is unfilled, and the test section lacks specific test results. The checklist items are unchecked.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.
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
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.
Autodiscovery "versionfilters" becomes "tracks", before it is released. Each track has a name and sets "versionfilter", "age" or both, so one crawler can, for example, take minor updates after 3 days and major updates after 14 days.
A track setting can't also be set on the crawler. Unknown track settings are rejected, and "age" is only accepted, and offered by the json schema, for crawlers supporting it. The generated pipelines are labelled with "updatecli.io/track" instead of "updatecli.io/versionfilter".
Fix #XXX
Test
To test this pull request, you can run the following commands:
Additional Information
Checklist
Tradeoff
Potential improvement
Summary by CodeRabbit
tracksand nest version-filter settings within each track.