Skip to content

[9.4] (backport #22422) fix: bump beats and drop elastic-agent-libs usage - #22560

Open
mergify[bot] wants to merge 3 commits into
9.4from
mergify/bp/9.4/pr-22422
Open

mergify[bot] wants to merge 3 commits into
9.4from
mergify/bp/9.4/pr-22422

Conversation

@mergify

@mergify mergify Bot commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

Motivation/summary

bump beats and update code to drop elastic-agent-libs usage

Checklist

For functional changes, consider:

  • Is it observable through the addition of either logging or metrics?
  • Is its use being published in telemetry to enable product improvement?
  • Have system tests been added to avoid regression?

How to test these changes

Related issues


This is an automatic backport of pull request #22422 done by [Mergify](https://mergify.com).

* fix: bump beats and resolve compile errors

* lint: make notice

* Update beat_test.go

* lint: drop elastic-agent-libs

* Update keystore_nofips_test.go

(cherry picked from commit f77f498)

# Conflicts:
#	NOTICE-fips.txt
#	NOTICE.txt
#	go.mod
#	go.sum
#	internal/beatcmd/keystore_nofips_test.go
#	internal/publish/pub_test.go
@mergify
mergify Bot requested a review from a team as a code owner November 24, 2026 13:23
@mergify mergify Bot added backport conflicts There is a conflict in the backported pull request labels Nov 24, 2026
Copilot AI balanced review requested due to automatic review settings November 24, 2026 13:23
@mergify

mergify Bot commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Cherry-pick of f77f498 has failed:

On branch mergify/bp/9.4/pr-22422
Your branch is up to date with 'origin/9.4'.

You are currently cherry-picking commit f77f498.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   internal/agentcfg/cache.go
	modified:   internal/agentcfg/cache_test.go
	modified:   internal/agentcfg/elasticsearch.go
	modified:   internal/agentcfg/elasticsearch_test.go
	modified:   internal/agentcfg/kibana.go
	modified:   internal/agentcfg/kibana_test.go
	modified:   internal/agentcfg/reporter.go
	modified:   internal/agentcfg/reporter_test.go
	modified:   internal/beatcmd/beat.go
	modified:   internal/beatcmd/beat_test.go
	modified:   internal/beatcmd/cmd.go
	modified:   internal/beatcmd/config.go
	modified:   internal/beatcmd/config_fips.go
	modified:   internal/beatcmd/config_nofips.go
	modified:   internal/beatcmd/config_nofips_test.go
	modified:   internal/beatcmd/config_test.go
	modified:   internal/beatcmd/keystore_nofips.go
	modified:   internal/beatcmd/locker.go
	modified:   internal/beatcmd/logging.go
	modified:   internal/beatcmd/logging_test.go
	modified:   internal/beatcmd/reloader.go
	modified:   internal/beatcmd/reloader_test.go
	modified:   internal/beatcmd/run.go
	modified:   internal/beatcmd/testcmd.go
	modified:   internal/beater/api/config/agent/handler_test.go
	modified:   internal/beater/api/expvar.go
	modified:   internal/beater/api/intake/handler.go
	modified:   internal/beater/api/mux.go
	modified:   internal/beater/api/mux_intake_rum_test.go
	modified:   internal/beater/api/mux_test.go
	modified:   internal/beater/api/root/handler.go
	modified:   internal/beater/auth/anonymous_test.go
	modified:   internal/beater/auth/apikey_test.go
	modified:   internal/beater/auth/authenticator.go
	modified:   internal/beater/auth/authenticator_test.go
	modified:   internal/beater/beater.go
	modified:   internal/beater/beater_test.go
	modified:   internal/beater/beatertest/output.go
	modified:   internal/beater/beatertest/server.go
	modified:   internal/beater/config/agentconfig.go
	modified:   internal/beater/config/agentconfig_test.go
	modified:   internal/beater/config/aggregation_test.go
	modified:   internal/beater/config/auth.go
	modified:   internal/beater/config/auth_test.go
	modified:   internal/beater/config/config.go
	modified:   internal/beater/config/config_test.go
	modified:   internal/beater/config/kibana.go
	modified:   internal/beater/config/rum.go
	modified:   internal/beater/config/rum_test.go
	modified:   internal/beater/config/sampling.go
	modified:   internal/beater/config/sampling_test.go
	modified:   internal/beater/http.go
	modified:   internal/beater/interceptors/auth_test.go
	modified:   internal/beater/interceptors/logging.go
	modified:   internal/beater/interceptors/logging_test.go
	modified:   internal/beater/interceptors/metrics.go
	modified:   internal/beater/interceptors/metrics_test.go
	modified:   internal/beater/memlimit_cgroup_test.go
	modified:   internal/beater/middleware/log_middleware.go
	modified:   internal/beater/middleware/log_middleware_test.go
	modified:   internal/beater/middleware/middleware.go
	modified:   internal/beater/otlp/grpc_test.go
	modified:   internal/beater/otlp/http_internal_test.go
	modified:   internal/beater/otlp/http_test.go
	modified:   internal/beater/request/context.go
	modified:   internal/beater/request/context_test.go
	modified:   internal/beater/server.go
	modified:   internal/beater/server_test.go
	modified:   internal/beater/telemetry.go
	modified:   internal/beater/telemetry_test.go
	modified:   internal/beater/tracing.go
	modified:   internal/beater/tracing_test.go
	modified:   internal/beater/waitready.go
	modified:   internal/elasticsearch/client.go
	modified:   internal/elasticsearch/client_test.go
	modified:   internal/elasticsearch/config.go
	modified:   internal/elasticsearch/security_api_test.go
	modified:   internal/kibana/client.go
	modified:   internal/kibana/client_test.go
	modified:   internal/kibana/send_config.go
	modified:   internal/kibana/send_config_test.go
	modified:   internal/logs/ratelimit.go
	modified:   internal/logs/ratelimit_test.go
	modified:   internal/publish/acker.go
	modified:   internal/sourcemap/body_caching.go
	modified:   internal/sourcemap/body_caching_test.go
	modified:   internal/sourcemap/chained.go
	modified:   internal/sourcemap/elasticsearch.go
	modified:   internal/sourcemap/elasticsearch_test.go
	modified:   internal/sourcemap/kibana.go
	modified:   internal/sourcemap/kibana_test.go
	modified:   internal/sourcemap/metadata_fetcher.go
	modified:   internal/sourcemap/metadata_fetcher_test.go
	modified:   internal/sourcemap/processor.go
	modified:   internal/sourcemap/processor_test.go
	modified:   internal/sourcemap/sourcemap_fetcher.go
	modified:   internal/sourcemap/sourcemap_fetcher_test.go
	modified:   x-pack/apm-server/aggregation/lsm.go
	modified:   x-pack/apm-server/main.go
	modified:   x-pack/apm-server/main_test.go
	modified:   x-pack/apm-server/sampling/config_test.go
	modified:   x-pack/apm-server/sampling/eventstorage/pebble.go
	modified:   x-pack/apm-server/sampling/eventstorage/prefix_test.go
	modified:   x-pack/apm-server/sampling/eventstorage/storage_bench_test.go
	modified:   x-pack/apm-server/sampling/eventstorage/storage_manager.go
	modified:   x-pack/apm-server/sampling/eventstorage/storage_manager_bench_test.go
	modified:   x-pack/apm-server/sampling/eventstorage/storage_manager_test.go
	modified:   x-pack/apm-server/sampling/processor.go
	modified:   x-pack/apm-server/sampling/processor_bench_test.go
	modified:   x-pack/apm-server/sampling/processor_test.go
	modified:   x-pack/apm-server/sampling/pubsub/config.go
	modified:   x-pack/apm-server/sampling/pubsub/pubsub.go
	modified:   x-pack/apm-server/sampling/pubsub/pubsub_integration_test.go
	modified:   x-pack/apm-server/sampling/pubsub/pubsub_test.go

Unmerged paths:
  (use "git add/rm <file>..." as appropriate to mark resolution)
	both modified:   NOTICE-fips.txt
	both modified:   NOTICE.txt
	both modified:   go.mod
	both modified:   go.sum
	deleted by us:   internal/beatcmd/keystore_nofips_test.go
	both modified:   internal/publish/pub_test.go

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@github-actions

Copy link
Copy Markdown
Contributor

🤖 GitHub comments

Just comment with:

  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Unresolved conflicts in the module files and publish test imports, along with undefined helpers in the non-FIPS tests, block module loading and test compilation.

3 open issues
What changed in this PR

This backports #22422 to 9.4, updating Beats and migrating APM Server from elastic-agent-libs to the corresponding Beats packages.

Changes:

  • Migrates production code, tests, and benchmarks to Beats logging, configuration, monitoring, and utility packages.
  • Updates dependencies and notices, and adapts management calls to ConfigFromControlProtocol.
  • Modernizes several Go constructs and adds non-FIPS keystore command tests.
File Description
x-pack/​apm-server/​sampling/​pubsub/​pubsub.go Migrates pubsub logging.
x-pack/​apm-server/​sampling/​pubsub/​pubsub_test.go Migrates logging test helpers.
x-pack/​apm-server/​sampling/​pubsub/​pubsub_integration_test.go Migrates integration-test logging.
x-pack/​apm-server/​sampling/​pubsub/​config.go Migrates logger configuration type.
x-pack/​apm-server/​sampling/​processor.go Migrates sampling logging.
x-pack/​apm-server/​sampling/​processor_test.go Migrates sampling test logging.
x-pack/​apm-server/​sampling/​processor_bench_test.go Migrates benchmark logging.
x-pack/​apm-server/​sampling/​eventstorage/​storage_manager.go Migrates storage-manager logging.
x-pack/​apm-server/​sampling/​eventstorage/​storage_manager_test.go Migrates storage test logging.
x-pack/​apm-server/​sampling/​eventstorage/​storage_manager_bench_test.go Migrates benchmark logging.
x-pack/​apm-server/​sampling/​eventstorage/​storage_bench_test.go Migrates benchmark logging.
x-pack/​apm-server/​sampling/​eventstorage/​prefix_test.go Migrates logging test helpers.
x-pack/​apm-server/​sampling/​eventstorage/​pebble.go Migrates Pebble logging.
x-pack/​apm-server/​sampling/​config_test.go Migrates logging test helpers.
x-pack/​apm-server/​main.go Migrates configuration, logging, and paths.
x-pack/​apm-server/​main_test.go Migrates logging and path helpers.
x-pack/​apm-server/​aggregation/​lsm.go Migrates aggregation logging.
NOTICE.txt Updates normal-build dependency notices.
NOTICE-fips.txt Updates FIPS dependency notices.
internal/​sourcemap/​sourcemap_fetcher.go Migrates fetcher logging.
internal/​sourcemap/​sourcemap_fetcher_test.go Migrates fetcher test logging.
internal/​sourcemap/​processor.go Migrates logging and reverse iteration.
internal/​sourcemap/​processor_test.go Migrates processor test logging.
internal/​sourcemap/​metadata_fetcher.go Migrates metadata-fetcher logging.
internal/​sourcemap/​metadata_fetcher_test.go Migrates metadata test logging.
internal/​sourcemap/​kibana.go Migrates Kibana fetcher logging.
internal/​sourcemap/​kibana_test.go Migrates Kibana and logging imports.
internal/​sourcemap/​elasticsearch.go Migrates logging and error matching.
internal/​sourcemap/​elasticsearch_test.go Migrates Elasticsearch test logging.
internal/​sourcemap/​chained.go Migrates chained-fetcher logging.
internal/​sourcemap/​body_caching.go Migrates cache logging.
internal/​sourcemap/​body_caching_test.go Migrates cache test logging.
internal/​publish/​pub_test.go Updates publisher-test imports.
internal/​publish/​acker.go Uses a typed atomic counter.
internal/​logs/​ratelimit.go Migrates rate-limited logging types.
internal/​logs/​ratelimit_test.go Migrates logging test helpers.
internal/​kibana/​send_config.go Migrates map utilities.
internal/​kibana/​send_config_test.go Migrates configuration imports.
internal/​kibana/​client.go Migrates the Kibana client package.
internal/​kibana/​client_test.go Migrates Kibana test imports.
internal/​elasticsearch/​security_api_test.go Migrates security API test logging.
internal/​elasticsearch/​config.go Migrates logging and transport packages.
internal/​elasticsearch/​client.go Migrates client logging.
internal/​elasticsearch/​client_test.go Migrates client test logging.
internal/​beater/​waitready.go Migrates logging and error matching.
internal/​beater/​tracing.go Migrates logging and monitoring.
internal/​beater/​tracing_test.go Migrates configuration imports.
internal/​beater/​telemetry.go Migrates telemetry monitoring.
internal/​beater/​telemetry_test.go Migrates monitoring test imports.
internal/​beater/​server.go Migrates logging and paths.
internal/​beater/​server_test.go Migrates configuration imports.
internal/​beater/​request/​context.go Migrates request logging.
internal/​beater/​request/​context_test.go Migrates request test logging.
internal/​beater/​otlp/​http_test.go Migrates logging and monitoring imports.
internal/​beater/​otlp/​http_internal_test.go Migrates HTTP test logging.
internal/​beater/​otlp/​grpc_test.go Migrates gRPC test logging.
internal/​beater/​middleware/​middleware.go Uses reverse slice iteration.
internal/​beater/​middleware/​log_middleware.go Migrates middleware logging.
internal/​beater/​middleware/​log_middleware_test.go Migrates logging and map utilities.
internal/​beater/​memlimit_cgroup_test.go Migrates optional-value utilities.
internal/​beater/​interceptors/​metrics.go Migrates metrics-interceptor logging.
internal/​beater/​interceptors/​metrics_test.go Migrates metrics test logging.
internal/​beater/​interceptors/​logging.go Migrates logging-interceptor types.
internal/​beater/​interceptors/​logging_test.go Migrates interceptor test logging.
internal/​beater/​interceptors/​auth_test.go Migrates authentication test logging.
internal/​beater/​http.go Migrates logging and TLS configuration.
internal/​beater/​config/​sampling.go Migrates sampling configuration imports.
internal/​beater/​config/​sampling_test.go Migrates configuration and logging helpers.
internal/​beater/​config/​rum.go Migrates RUM configuration imports.
internal/​beater/​config/​rum_test.go Migrates configuration and logging helpers.
internal/​beater/​config/​kibana.go Migrates configuration and Kibana packages.
internal/​beater/​config/​config.go Migrates configuration, logging, and TLS types.
internal/​beater/​config/​config_test.go Migrates imports and updates a comment.
internal/​beater/​config/​auth.go Migrates authentication configuration imports.
internal/​beater/​config/​auth_test.go Migrates configuration and logging helpers.
internal/​beater/​config/​aggregation_test.go Migrates configuration and logging helpers.
internal/​beater/​config/​agentconfig.go Migrates agent configuration imports.
internal/​beater/​config/​agentconfig_test.go Migrates configuration and logging helpers.
internal/​beater/​beatertest/​server.go Migrates server-test support packages.
internal/​beater/​beatertest/​output.go Migrates output-test configuration.
internal/​beater/​beater.go Migrates configuration and runtime utilities.
internal/​beater/​beater_test.go Migrates configuration, logging, and monitoring helpers.
internal/​beater/​auth/​authenticator.go Migrates authenticator logging.
internal/​beater/​auth/​authenticator_test.go Migrates authenticator test logging.
internal/​beater/​auth/​apikey_test.go Migrates API-key test logging.
internal/​beater/​auth/​anonymous_test.go Migrates anonymous-auth test logging.
internal/​beater/​api/​root/​handler.go Migrates response map utilities.
internal/​beater/​api/​mux.go Migrates logging and monitoring.
internal/​beater/​api/​mux_test.go Migrates logging and monitoring helpers.
internal/​beater/​api/​mux_intake_rum_test.go Migrates RUM intake test logging.
internal/​beater/​api/​intake/​handler.go Uses typed error matching.
internal/​beater/​api/​expvar.go Migrates monitoring registry imports.
internal/​beater/​api/​config/​agent/​handler_test.go Migrates agent-config test logging.
internal/​beatcmd/​testcmd.go Migrates configuration, logging, and test utilities.
internal/​beatcmd/​run.go Migrates service utilities.
internal/​beatcmd/​reloader.go Migrates configuration and logging.
internal/​beatcmd/​reloader_test.go Migrates reloader test helpers.
internal/​beatcmd/​logging.go Migrates logging and paths.
internal/​beatcmd/​logging_test.go Migrates logging configuration helpers.
internal/​beatcmd/​locker.go Migrates path utilities.
internal/​beatcmd/​keystore_nofips.go Migrates the keystore package.
internal/​beatcmd/​keystore_nofips_test.go Adds keystore command and directory-import tests.
internal/​beatcmd/​config.go Migrates configuration, keystore, and paths.
internal/​beatcmd/​config_test.go Migrates configuration test imports.
internal/​beatcmd/​config_nofips.go Migrates non-FIPS configuration dependencies.
internal/​beatcmd/​config_nofips_test.go Migrates keystore test imports.
internal/​beatcmd/​config_fips.go Migrates FIPS configuration dependencies.
internal/​beatcmd/​cmd.go Migrates command logging.
internal/​beatcmd/​beat.go Migrates utilities and management API calls.
internal/​beatcmd/​beat_test.go Migrates imports and the mock management method.
internal/​agentcfg/​reporter.go Migrates reporter logging.
internal/​agentcfg/​reporter_test.go Migrates reporter test logging.
internal/​agentcfg/​kibana.go Migrates Kibana agent-config logging.
internal/​agentcfg/​kibana_test.go Migrates Kibana test logging.
internal/​agentcfg/​elasticsearch.go Migrates Elasticsearch agent-config logging.
internal/​agentcfg/​elasticsearch_test.go Migrates Elasticsearch test logging.
internal/​agentcfg/​cache.go Migrates agent-config cache logging.
internal/​agentcfg/​cache_test.go Migrates cache test logging.
go.sum Updates dependency checksums.
go.mod Updates direct and indirect dependencies.

Review effort: Balanced

Comment thread go.mod Outdated
github.com/dustin/go-humanize v1.1.0
github.com/elastic/apm-aggregation v1.5.1
github.com/elastic/apm-data v1.23.0
<<<<<<< HEAD
Comment thread internal/publish/pub_test.go Resolved
@elastic-vault-github-plugin-prod

Copy link
Copy Markdown
Contributor

Dependency Update Analysis

Summary: This PR updates Go dependencies (notably github.com/elastic/beats/v7) but is currently high risk because unresolved merge-conflict markers break module parsing/build.

github.com/elastic/beats/v7 v7.0.0-alpha2.0.20261020133911-c64f75eeac36 → v7.0.0-alpha2.0.20261109221706-f2982798020f (with related Go bumps)

Ecosystem: Go

Check Result
Breaking changes ⚠️ Found (branch contains unresolved conflict markers in dependency/code files)
Testable in PR ✅ Yes (.github/workflows/ci.yml runs on pull_request)
Changelog highlights (old → new)
  • elastic-agent-client has an upstream release note for v7.21.0 (drops deprecated elastic-agent-libs usage).
  • go-docappender v2.14.1 → v2.15.0 release notes indicate feature/dependency maintenance changes.
  • For the Beats pseudo-version bump, exact release-note body was not available from tags/releases; local metadata indicates this PR intends to bump Beats and remove elastic-agent-libs usage.
  • No explicit CVE/GHSA entries were identified in the retrieved release-note content.
Usage in this repository
  • github.com/elastic/beats/v7 is used broadly across runtime code (e.g., internal/beater/*, internal/beatcmd/*, internal/agentcfg/*, x-pack/apm-server/*; 123 files matched).
  • github.com/elastic/elastic-agent-client/v7 is used in Fleet integration entry points (x-pack/apm-server/main.go) and tests.
  • github.com/elastic/elastic-agent-libs still appears in internal/publish/pub_test.go due unresolved conflict block.
Compatibility assessment

Current PR state is not compatible/buildable:

  • Unresolved markers in go.mod:12, go.mod:229, internal/publish/pub_test.go:32, NOTICE.txt:458, NOTICE-fips.txt:458.
  • Local validation fails immediately: go test ./internal/publish -run TestPublisherStop -count=1 with go.mod parse errors (malformed module path "<<<<<<<").

Until conflicts are resolved, this dependency update cannot be safely merged.

Labels Applied

No labels applied (overall risk: high).


What is this? | From workflow: Observability Agentic Workflow — Pull Request

Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.

@github-actions

Copy link
Copy Markdown
Contributor

TL;DR

Buildkite packaging fails for both x86_64 and aarch64 because PR #22560 contains unresolved merge-conflict markers in go.mod. Resolve the conflicts and rerun packaging.

Remediation

  • Resolve conflict blocks in go.mod and keep a single dependency set (remove all <<<<<<<, =======, >>>>>>> markers).

  • Validate before pushing:

    • git show HEAD:go.mod | grep -n '<<<<<<<\|=======\|>>>>>>>' (should return no matches)
    • go mod tidy and rerun .buildkite/scripts/package.sh staging (and snapshot if needed).
Investigation details

Root Cause

go.mod in the PR head contains unresolved merge-conflict markers at lines 12/16/19 and 229/232/250, which makes go.mod invalid and prevents the packaging build from determining a valid Go toolchain/container input.

Evidence

  • Build: https://buildkite.com/elastic/apm-server-package/builds/13808

  • Job/step: Package x86_64 and Package aarch64 (snapshot and staging)

  • Key log excerpt:

    • go: errors parsing go.mod:
    • go.mod:12: malformed module path "<<<<<<<": invalid char '<'
    • go.mod:229: malformed module path "<<<<<<<": invalid char '<'
    • ERROR: failed to build: ... failed to parse stage name "golang:": invalid reference format

Verification

  • Ran: git fetch --no-tags --quiet origin refs/pull/22560/head
  • Ran: git show FETCH_HEAD:go.mod | nl -ba | grep -n '<<<<<<<\|=======\|>>>>>>>'
  • Result: markers confirmed at lines 12,16,19,229,232,250.
  • Full test suite not run because failure occurs during initial packaging setup while parsing go.mod.

Follow-up

After resolving go.mod, re-run the same Buildkite package jobs; this failure should clear without further code changes.


What is this? | From workflow: Observability Agentic Workflow — Status

Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.

Merge current 9.4 and keep go 1.26.11. Pin beats to
v7.0.0-alpha2.0.20261124215226-a55859eabecd so the elastic-agent-libs
move uses this branch's updatecli revision. That revision still has
Manager.Enabled. Drop keystore_nofips_test.go; its helpers are not on 9.4.

Co-authored-by: Cursor <cursoragent@cursor.com>
Copilot AI balanced review requested due to automatic review settings November 26, 2026 15:35

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

NOTICE.txt embeds local sandbox paths instead of the normalized $GOMODCACHE prefix, making it machine-dependent and causing CI regeneration to fail the make check-full clean-tree check.

2 open issues
2 resolved since last review

Review effort: Balanced

Comment thread NOTICE.txt
--------------------------------------------------------------------------------

Contents of probable licence file $GOMODCACHE/github.com/!kim!machine!gun/automemlimit@v1.0.0/LICENSE:
Contents of probable licence file /var/folders/t6/f676yv596gj2h72lwcw3y2940000gn/T/cursor-sandbox-cache/4a42307367094a8fda6e60746f035625/go-mod/github.com/!kim!machine!gun/automemlimit@v1.0.0/LICENSE:
@elastic-vault-github-plugin-prod

Copy link
Copy Markdown
Contributor

Dependency Update Analysis

Summary: This PR performs a Go dependency refresh centered on github.com/elastic/beats/v7 plus related direct/transitive bumps; overall risk is low-to-moderate, with no breaking changes found for current usage.

github.com/elastic/beats/v7 v7.0.0-alpha2.0.20261020133911-c64f75eeac36 → v7.0.0-alpha2.0.20261124215226-a55859eabecd

Ecosystem: Go

Check Result
Breaking changes ✅ None found in repo usage after required import-path updates in this PR
Testable in PR ✅ Yes — repository CI is triggered on pull_request (.github/workflows/ci.yml)
Changelog highlights (old → new)

Upstream release notes for this pseudo-version SHA bump were unavailable via GitHub Releases (no exact-equivalent release tag for this pseudo-version); local metadata confirms this is the intended beats pin update plus code adjustments to drop direct elastic-agent-libs imports.

Security/CVE assessment: no explicit CVE/GHSA entries available from upstream notes for this pseudo-version; local diff shows import migration to beats-owned packages with no new privileged/sensitive integration points.

Usage in this repository

Widely used across runtime and tests (examples: internal/beatcmd/beat.go, internal/beater/auth/authenticator.go, x-pack/apm-server/main.go).
This PR updates consumed package paths from github.com/elastic/elastic-agent-libs/* to github.com/elastic/beats/v7/pkg/* in touched code.

Compatibility assessment

The PR includes required source updates for moved APIs (config/logp/paths/keystore/etc.), and targeted tests pass:

  • go test ./internal/beater/auth -run TestAuthenticator -count=1 ✅
  • go test ./internal/beatcmd -run 'Test(Beat|Keystore)' -count=1 ✅ (compiles package; no matching tests)
  • go test ./internal/publish -run Test -count=1 ✅

No evidence of removed APIs still being referenced.

github.com/elastic/elastic-agent-client/v7 v7.18.1 → v7.20.0

Ecosystem: Go

Check Result
Breaking changes ✅ None found
Testable in PR ✅ Yes
Changelog highlights (v7.18.1 → v7.20.0)

From upstream releases (v7.19.0, v7.20.0):

  • Added agent tags / trigger unit updates on AgentInfo changes.
  • gRPC client lifecycle fix: close connection when client stops.

Security/CVE assessment: no explicit CVE/GHSA disclosures in release notes; connection-lifecycle fix is risk-reducing (resource/connection hygiene), not risk-increasing.

Usage in this repository

Used via beats/apm-server integrations (indirectly through runtime components; no direct API break surfaced in compile/tests touched by this PR).

Compatibility assessment

No major-version change, no import-path change, and no consumed API removals observed in this repo diff.

github.com/elastic/go-docappender/v2 v2.14.1 → v2.15.0

Ecosystem: Go

Check Result
Breaking changes ✅ None found
Testable in PR ✅ Yes
Changelog highlights (v2.14.1 → v2.15.0)

Upstream highlights include:

  • Added doc counts to BulkIndexerResponseStat.
  • Dependency bumps and routine maintenance.

Security/CVE assessment: no CVE/GHSA entries listed; change appears additive/observability-focused and low risk.

Usage in this repository

Used in data publishing paths and tests (examples: internal/beater/beater.go, internal/beater/processors.go, x-pack/apm-server/sampling/pubsub/pubsub.go).

Compatibility assessment

No breaking API migration required in this PR for docappender usage.

go.opentelemetry.io/collector/pdata v1.69.0 → v1.71.0 (module set release v0.163.0 → v0.165.0)

Ecosystem: Go

Check Result
Breaking changes ✅ None found for consumed pdata APIs
Testable in PR ✅ Yes
Changelog highlights (v1.69.0 → v1.71.0)

Mapped upstream release notes show:

  • Breaking removal in pkg/confighttp deprecated fields (not used by this repo’s pdata usage).
  • pdata performance improvements.
  • Security-relevant hardening fixes (zstd decoder bounds; recursion depth limits preventing stack-overflow on deeply nested payloads).

Security/CVE assessment: no explicit CVE IDs listed, but fixes reduce DoS-style exposure in parsing/decompression paths.

Usage in this repository

OTLP ingest/encoding paths use pdata and OTLP protocol helpers (examples: internal/beater/otlp/grpc.go, internal/beater/otlp/http.go, related tests).

Compatibility assessment

Current usage is centered on plogotlp/pmetricotlp/ptraceotlp; no consumed interface removals identified.

Additional notable direct bump: google.golang.org/grpc v1.84.0 → v1.85.0

Ecosystem: Go

Check Result
Breaking changes ✅ None found in current usage
Testable in PR ✅ Yes
Changelog highlights (v1.84.0 → v1.85.0)

Upstream includes bug fixes around HTTP/2 stream handling, metadata validation, authority handling, and transport robustness; also minor new features.

Security/CVE assessment: metadata validation and protocol-handling fixes are risk-reducing for request-handling surfaces. No explicit CVE IDs were listed in release notes.

Usage in this repository

Used broadly by server/interceptor and OTLP gRPC code (examples: internal/beater/server.go, internal/beater/otlp/grpc.go, internal/beater/interceptors/*.go).

Compatibility assessment

No major-version bump and no required code changes detected for grpc-specific APIs.

Labels Applied

  • oblt-aw/ai/merge-ready — applied. Overall risk is within policy ceiling (low-to-moderate) and no breaking changes affecting repository usage were found.

Warning

Firewall blocked 1 domain

The following domain was blocked by the firewall during workflow execution:

  • testing.invalid

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "testing.invalid"

See Network Configuration for more information.


What is this? | From workflow: Observability Agentic Workflow — Pull Request

Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.

@github-actions

Copy link
Copy Markdown
Contributor

Automerge skipped

Automerge skipped this pull request because the all-files collection is not enabled for this repository.

To allow automerge for this kind of update, enable the matching collection under Automerge on the Control Plane Dashboard (the oblt-aw/dashboard issue). See Automerge dependency collections for what each collection covers.

See Opt in or opt out for how to enable or disable Automerge collections on the Control Plane Dashboard.

Collections currently enabled for automerge: github-actions, pre-commit, updatecli

Changed files considered:

  • NOTICE-fips.txt

  • NOTICE.txt

  • go.mod

  • go.sum

  • internal/agentcfg/cache.go

  • internal/agentcfg/cache_test.go

  • internal/agentcfg/elasticsearch.go

  • internal/agentcfg/elasticsearch_test.go

  • internal/agentcfg/kibana.go

  • internal/agentcfg/kibana_test.go

  • internal/agentcfg/reporter.go

  • internal/agentcfg/reporter_test.go

  • internal/beatcmd/beat.go

  • internal/beatcmd/beat_test.go

  • internal/beatcmd/cmd.go

  • internal/beatcmd/config.go

  • internal/beatcmd/config_fips.go

  • internal/beatcmd/config_nofips.go

  • internal/beatcmd/config_nofips_test.go

  • internal/beatcmd/config_test.go

  • …and 99 more

Run the updatecli go get for beats@9.4. That tip requires go 1.27.4.

Co-authored-by: Cursor <cursoragent@cursor.com>
Copilot AI balanced review requested due to automatic review settings November 26, 2026 17:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

The licence headings in NOTICE.txt contain a machine-specific module-cache path rather than $GOMODCACHE, making regeneration non-reproducible across machines and risking unrelated diffs in CI’s clean-tree check.

2 open issues

Review effort: Balanced

Comment thread go.mod
Comment on lines +12 to +13
github.com/elastic/beats/v7 v7.0.0-alpha2.0.20261126112628-a335670a011e
github.com/elastic/elastic-agent-client/v7 v7.20.0

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[For reviewers] Beats version is updated as per https://github.com/elastic/apm-server/pull/22194/changes

@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

💚 Build Succeeded

History

cc @kruskall

@elastic-vault-github-plugin-prod

Copy link
Copy Markdown
Contributor

Dependency Update Analysis

Summary: This PR updates github.com/elastic/beats/v7 to a newer pseudo-version and aligns Go/tooling transitive modules; overall risk is low-to-moderate (policy-eligible), with no breaking changes identified for this repo’s current usage.

Dependency 1: github.com/elastic/beats/v7 v7.0.0-alpha2.0.20261124215226-a55859eabecd → v7.0.0-alpha2.0.20261126112628-a335670a011e

Ecosystem: Go

Check Result
Breaking changes ✅ None found for consumed Beats APIs/import paths in this repo
Testable in PR ✅ Yes — PR has build / check and build / build check-runs on this PR context
Changelog highlights (vOLD → vNEW)

No exact GitHub Release tag exists for this pseudo-version bump (MCP release lookup returned 404; no exact-equivalent tag in releases list), so local/upstream commit metadata was used.

The new Beats commit (a335670a011e) is a Go 1.27.4 backport/update focused on:

  • Moving Beats to Go 1.27.4
  • Test/format adjustments for Go 1.27 behavior changes (JSON error wording, HTTP connection reuse, gofmt alignment)
  • Regenerated compressed assets and conflict-resolution backport maintenance

Security/CVE-focused assessment:

  • No explicit CVE/GHSA entries were identified in the available metadata for this specific bump.
  • Changes appear maintenance/toolchain-oriented; no new privileged feature surface for APM Server was evident from this PR’s usage context.
Usage in this repository

github.com/elastic/beats/v7 is heavily used across runtime and tests (262 matches in 122 Go files), notably in:

  • internal/beatcmd/*
  • internal/beater/* and internal/beater/config/*
  • internal/elasticsearch/*, internal/sourcemap/*, internal/agentcfg/*
  • x-pack/apm-server/*

Consumed areas include libbeat lifecycle/config/logging/monitoring/output plumbing and related helpers.

Compatibility assessment

No import-path major-version transition occurred (/v7 unchanged), and this PR does not alter local call sites. The go directive was raised to 1.27.4, matching the upstream Beats requirement, which avoids toolchain mismatch. Net effect is compatible for current repo usage.

Dependency 2: Go toolchain in go.mod 1.26.11 → 1.27.4

Ecosystem: Go

Check Result
Breaking changes ✅ None found in this repo’s code from this PR change set
Testable in PR ✅ Yes — PR checks run in PR context
Changelog highlights (vOLD → vNEW)

Toolchain uplift aligns with upstream Beats pin and associated tidy output.
Security/CVE-focused assessment:

  • No direct CVE claim is made from this PR metadata.
  • This primarily keeps the branch aligned with upstream dependency/toolchain expectations.
Usage in this repository

Applies repository-wide at build/test time via go.mod toolchain directive.

Compatibility assessment

No module major-version import-path breaks introduced in this PR. Main operational impact is requiring Go 1.27.4-capable environments.

Dependency 3: Indirect module bumps from go.mod/go.sum

  • dario.cat/mergo v1.0.1 → v1.0.2
  • github.com/ProtonMail/go-crypto v1.1.6 → v1.3.0
  • github.com/go-git/go-billy/v5 v5.8.0 → v5.9.2
  • github.com/go-git/go-git/v5 v5.17.1 → v5.19.3
  • github.com/pjbgf/sha1cd v0.3.2 → v0.7.0

Ecosystem: Go

Check Result
Breaking changes ✅ None found for this repo’s direct code paths (all remain indirect)
Testable in PR ✅ Yes — PR checks run in PR context
Changelog highlights (vOLD → vNEW)

Release notes were available for these GitHub-hosted modules and indicate mostly maintenance/security-hardening/perf changes:

  • go-git/go-billy: include dependency security updates (e.g., x/crypto, x/net, x/text) and transport hardening notes.
  • go-crypto: hash/signature policy hardening and decompression limit support.
  • mergo: maintenance cleanup.
  • sha1cd: performance/fuzzing/arch improvements.

Security/CVE-focused assessment:

  • No explicit CVE IDs were observed in the fetched notes; security-related items trend toward risk reduction/hardening.
  • No evidence from this PR that these introduce new exposed attack surface in APM Server runtime.
Usage in this repository

No direct imports found in repository Go source for these modules. go mod why -m resolves them through tooling paths (not runtime), primarily via github.com/goreleaser/nfpm/v2 / github.com/goreleaser/chglog from the tool (...) block in go.mod.

Compatibility assessment

All are non-major import-path bumps in this PR context, with no direct call-site coupling in runtime code. Compatibility risk is low.

Labels Applied

  • oblt-aw/ai/merge-ready — applied (overall risk low-to-moderate, within policy ceiling; no breaking changes affecting this repository usage).

What is this? | From workflow: Observability Agentic Workflow — Pull Request

Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.

Comment thread go.mod
module github.com/elastic/apm-server

go 1.26.11
go 1.27.4

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

blocked by #21924

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport conflicts There is a conflict in the backported pull request oblt-aw/ai/merge-ready

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants