Skip to content

[9.3] [Fleet] only auto-install content packages newer than the installed version#262704

Merged
juliaElastic merged 3 commits into
elastic:9.3from
juliaElastic:backport-262509-to-9.3
Apr 13, 2026
Merged

[9.3] [Fleet] only auto-install content packages newer than the installed version#262704
juliaElastic merged 3 commits into
elastic:9.3from
juliaElastic:backport-262509-to-9.3

Conversation

@juliaElastic
Copy link
Copy Markdown
Contributor

Summary

Backport of #262509 to 9.3.

The auto-install content packages task was using string equality (!== version) to decide whether to reinstall a package. This meant any version mismatch would trigger a reinstall, effectively downgrading packages.

The fix replaces string equality with semverGt to ensure a package is only installed when the registry version is strictly newer than the installed version.

…ersion

Backport of elastic#262509 to 9.3

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@juliaElastic juliaElastic added the backport This PR is a backport of another PR label Apr 13, 2026
@botelastic botelastic Bot added the Team:Fleet Team label for Observability Data Collection Fleet team label Apr 13, 2026
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/fleet (Team:Fleet)

@macroscopeapp
Copy link
Copy Markdown
Contributor

macroscopeapp Bot commented Apr 13, 2026

Approvability

Verdict: Needs human review

This PR modifies runtime behavior in Fleet's auto-install task by switching from simple version equality to semver comparison, preventing package downgrades when newer prereleases are installed. The behavioral change is well-tested but affects automatic package management logic. Additionally, the author does not own the modified files (owned by @kibanamachine), so designated code owner review is warranted.

You can customize Macroscope's approvability policy. Learn more.

@jillguyonnet
Copy link
Copy Markdown
Member

Backport looks good - any reason the test was not backported? (same question for #262703)

Backport of elastic#262509 test changes to 9.3

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@juliaElastic juliaElastic enabled auto-merge (squash) April 13, 2026 08:52
@juliaElastic juliaElastic merged commit c2163a7 into elastic:9.3 Apr 13, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR Team:Fleet Team label for Observability Data Collection Fleet team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants