Skip to content

[9.6] (backport #17977) feat: update OTel Collector components from 0.164.x to 0.165.x - #18049

Merged
andrzej-stencel merged 1 commit into
elastic:9.6from
andrzej-stencel:backport-17977-9.6
Nov 17, 2026
Merged

andrzej-stencel merged 1 commit into
elastic:9.6from
andrzej-stencel:backport-17977-9.6

Conversation

@andrzej-stencel

Copy link
Copy Markdown
Contributor

Related issues

Risk

  • Low: isolated change, no effect on Fleet connectivity, policy handling, or upgrades
  • Medium: changes existing behavior, but is feature flagged or a failure does not affect Fleet connectivity, policy handling, or upgrades
  • High: touches Fleet connectivity, policy application, upgrade/rollback, installation, or changes defaults for existing users

Rationale

Manual backport of #17977, because Mergify could not resolve the conflicts.

This PR updates the OTel Collector components from 0.164.x to 0.165.x (core v0.165.0 / v1.71.0, contrib v0.165.1, Elastic OTel components v0.81.0), as #17977 did on main. It also removes settings that the updated components no longer accept (mapping::mode on the Elasticsearch exporter, keep_alives_enabled on the injected healthcheckv2 config), and moves the status-watching extensions to extensioncapabilities.ComponentStatusWatcher.

It bumps the beats submodule from 156184c290 to e7cba3c87c, the current head of Beats 9.6, which brings in these Beats 9.6 commits:

How the conflicts were resolved:

All other files applied cleanly.

Rollout and safety

Same as #17977: configurations that still set the removed settings will fail to validate after this update. The changelog fragments from #17977 are included.

Testing

  • go build ./... and go vet pass for both Go modules.
  • Unit tests of internal/pkg/otel/... (the OTel manager ones with the internal/edot/testing collector binary built), dev-tools/mage/otel, internal/pkg/agent/application/... and all internal/edot packages pass. The exception is the coordinator tests that chown a fake component binary, which can't run in my local sandbox.
  • mage check passes with no changes.

🤖 Generated with Claude Code

…ic#17977)

* Update elastic/beats to 65bae9ee687e

Also updates OTel Collector components from 0.164.x to 0.165.x:
Core v0.165.0 / v1.71.0, Contrib v0.165.1 (k8sattributesprocessor v1.4.1),
and Elastic OTel components to v0.81.0.

Removes settings that are no longer accepted by the updated components:
- `keep_alives_enabled` from the healthcheckv2 extension config injected
  by the OTel manager (removed from confighttp server settings).
- `mapping::mode` from the Elasticsearch exporter in samples, Helm chart,
  docs and test data (removed from the exporter; it was already ignored).

Created-by: Claude Opus 5.5
Co-authored-by: Cursor <cursoragent@cursor.com>

* Use beats/v7/pkg types in heartbeat browser CA integration test

The test was added with elastic-agent-libs imports while elastic#17917 moved the
shared test helpers to beats/v7/pkg, so the testing/integration/ess package
no longer compiled.

Created-by: Claude Opus 5.5
Co-authored-by: Cursor <cursoragent@cursor.com>

* Remove unsupported sending_queue from prometheus_remote_write test configs

The Prometheus remote write exporter has never supported sending_queue
(it uses remote_write_queue). Before confighttp v1.71.0, the custom
Unmarshal of the squash-embedded confighttp.ClientConfig used
WithIgnoreUnused, which made the exporter silently accept unknown keys.
confighttp v1.71.0 dropped that Unmarshal, so unknown keys are now
rejected and the collector failed to start in these tests.

Created-by: Claude Opus 5.5
Co-authored-by: Cursor <cursoragent@cursor.com>

* Apply suggestion from @alexandra5000

Co-authored-by: Aleksandra Spilkowska <96738481+alexandra5000@users.noreply.github.com>

* Apply suggestion from @alexandra5000

Co-authored-by: Aleksandra Spilkowska <96738481+alexandra5000@users.noreply.github.com>

* docs: update removed versions

* fix: use extensioncapabilities.ComponentStatusWatcher in status-watching extensions

Collector v0.165.0 deprecated componentstatus.Watcher and no longer calls
it: the service now notifies only extensions that implement
extensioncapabilities.ComponentStatusWatcher (method Changed).

The elastic_diagnostics and elastic_meter_lifecycle extensions only
implemented the old interface, so they stopped receiving StatusStopped
events. Diagnostic hooks of receivers torn down by a partial reload were
never dropped (TestDiagnosticHooksDroppedOnPartialReload failed), and the
meters of stopped receivers were never released.

Implement the new interface in both extensions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* build: don't list extensioncapabilities as an EDOT component

The EDOT README generator treats every direct OTel dependency whose path
contains /extension/ as an extension component. The meterlifecycle
extension now imports extensioncapabilities directly for the
ComponentStatusWatcher interface, so the generator listed that API module
as an extension and check-ci failed on the stale README.

Skip modules that hold collector APIs rather than a component, starting
with extensioncapabilities.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Aleksandra Spilkowska <96738481+alexandra5000@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 073f69a)
@andrzej-stencel
andrzej-stencel requested review from a team as code owners November 17, 2026 09:59
@andrzej-stencel
andrzej-stencel requested review from blakerouse and removed request for a team November 17, 2026 09:59
@andrzej-stencel andrzej-stencel added enhancement New feature or request Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team backport labels Nov 17, 2026
@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane)

@mergify

mergify Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

This pull request is merged.

@andrzej-stencel
andrzej-stencel merged commit 5a43c8c into elastic:9.6 Nov 17, 2026
87 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport enhancement New feature or request Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants