[automation] Add requires-update workflow#19217
Open
teresaromero wants to merge 10 commits into
Open
Conversation
…ersions - Introduced a new `RequiresUpdate` function in `magefile.go` that triggers the update of required package versions for all integration packages. - Added a new `requiresupdate` package with functionality to process package updates, manage changelog entries, and handle dry-run scenarios. - The `Run` function in the `requiresupdate` package walks through integration packages, applies updates, and summarizes changes by codeowner. This enhancement streamlines the process of maintaining package dependencies and ensures integration packages are up-to-date.
Add requiresBlock and requiresEntry types to citools.packageManifest so the requires: field is parsed from the manifest. Requires is a pointer so nil unambiguously means the key was absent. HasRequires() lets callers skip packages before spawning any subprocess. Use HasRequires() in requiresupdate.Run() to avoid calling elastic-package for the large majority of packages that have no requires section. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Emit a structured JSON report (path via REQUIRES_UPDATE_JSON_OUT env var) grouping applied and skipped proposals by codeowner team, including the file paths written to disk. Consumed by the GitHub Actions script to drive per-team PRs and issues without duplicating CODEOWNERS logic in bash. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Scheduled GitHub Actions workflow (Monday 09:00 UTC) that runs mage RequiresUpdate and drives one PR per codeowner team for applied updates, or a GitHub issue for teams where all proposals were blocked. Includes --preview mode and a fixture-based test script. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ion logic Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
elastic-package requires update (without --dry-run) both returns the JSON proposals and writes the manifest. patchManifestRequires was duplicating that work. Now --dry-run is passed only when DRY_RUN=true. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
💔 Build Failed
Failed CI StepsHistory
|
4 tasks
🚀 Benchmarks reportPackage
|
| Data stream | Previous EPS | New EPS | Diff (%) | Result |
|---|---|---|---|---|
audit |
3436.43 | 2881.84 | -554.59 (-16.14%) | 💔 |
cloud_configuration_finding |
8928.57 | 6666.67 | -2261.9 (-25.33%) | 💔 |
cloud_configuration_finding_full_posture |
10101.01 | 6369.43 | -3731.58 (-36.94%) | 💔 |
issue |
4115.23 | 3333.33 | -781.9 (-19%) | 💔 |
To see the full report comment with /test benchmark fullreport
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.
Proposed commit message
Add a weekly scheduled workflow that runs
mage RequiresUpdateacross all integration packages andopens one PR per codeowner team with the manifest and changelog bumps. When a team's updates are all
Kibana-version-blocked, it opens a GitHub issue instead.
What changed:
mage RequiresUpdatewalkspackages/, callselastic-package requires update --format jsonto getproposals and apply manifest changes, adds changelog entries, and computes the next version by the
largest semver tier across applied bumps (major > minor > patch).
--dry-runis passed only whenDRY_RUN=true.It writes a JSON report grouped by codeowner team that the shell script reads to do all git and
GitHub operations: branch per team, commit, force-push,
gh pr createorgh issue create, and asecond commit that replaces the
pull/0changelog placeholder with the real PR number.Key decisions:
automated/requires-update-<slug>,stable and force-pushed so existing open PRs are updated in place rather than duplicated.
the changelog link post-PR-create, and cannot share one
elastic-packagebuild across targets.and file lists so the script needs no git-status parsing or CODEOWNERS re-derivation.
breaking-changechangelog type for major dep bumps — a major input-package version signalsan incompatible contract change surfaced through the integration's assets.
continue-on-error: trueon the mage step — one failing package should not block PRs forteams whose packages succeeded.
elastic-packagepinned to a commit —--format jsonis not yet in a released version;a TODO comment marks the pin for removal once it ships.
Preview (
bash .github/scripts/requires-update.sh --preview .github/scripts/testdata/requires-update.json):Checklist
changelog.ymlfile.Author's Checklist
--previewmode tested againsttestdata/requires-update.jsonfor all three cases (PR with updates, PR with partial skips, issue-only).automated/requires-update-*branches must not be branch-protected (same convention as dependabot/updatecli).How to test this PR locally
The workflow can also be triggered manually via
workflow_dispatchonce merged.Related issues
elastic-package requires updatecommand to bump requires pins from the registry elastic-package#3593