Skip to content

Conversation

@mergify
Copy link
Contributor

@mergify mergify bot commented Feb 24, 2025

What does this PR do?

Allows to run components in the Otel manager instead of the runtime manager. Currently, only filestream is supported. This implements option 2 from https://github.com/elastic/ingest-dev/issues/4931.

Some notes about the implementation:

  • We use the same otel collector as hybrid mode. We add a prefix to each component and pipeline name in an effort to avoid conflicts.
  • The Otel configuration is generated from the component model agent already uses for beats processes. It is easier to manipulate and lets us emit the same status information in the future.
  • This behaviour is controlled by a single attribute of the Coordinator, the only way to enable it is by changing the code. This is a temporary measure until we decide what feature flags we want for it.
  • Status reporting uses the otel collector status, and doesn't try to be compatible with beats processes status.
  • Which input types are supported is hardcoded.

Why is it important?

This is a preprequisite for migrating to Otel within agent, which is our long-term plan. In the short-term, it will make it easier for us to run tests.

Checklist

  • I have read and understood the pull request guidelines of this project.
  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an integration test or an E2E test

How to test this PR locally

  1. Change the boolean value in
    runComponentsInOtelManager: false, // change this to run supported components in the Otel manager
  2. Build an agent package
  3. Run agent with a configuration containing a filestream input

Related issues


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

@mergify mergify bot added the backport label Feb 24, 2025
@mergify mergify bot requested a review from a team as a code owner February 24, 2025 15:51
@mergify mergify bot removed the request for review from a team February 24, 2025 15:51
@github-actions github-actions bot added Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team skip-changelog labels Feb 24, 2025
@elasticmachine
Copy link
Contributor

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

* Add ability to run components in the Otel manager

# Conflicts:
#	NOTICE.txt
#	go.mod
#	go.sum

* Add coordinator test

* Set metricbeat receiver signal type to logs

* Drop unnecessary transform processor

The conversion now happens in the otel consumer in beats.

* Determine default datastream type from beat name

* Fix diagnostics tests

* Promote output queue settings to receivers

* Move otel config translation to the otel package

* Emit the otel component diagnostic conditionally

* Add more otel config translation tests

* Code review fixes

* Fix diagnostics tests

* Code Review fixes

* Correctly set input types if not present

* More code review fixes

(cherry picked from commit eeffc0e)
@swiatekm swiatekm force-pushed the mergify/bp/8.x/pr-6697 branch from fc56291 to b8f1463 Compare February 25, 2025 14:16
@elastic-sonarqube
Copy link

@elasticmachine
Copy link
Contributor

elasticmachine commented Feb 25, 2025

💚 Build Succeeded

History

cc @swiatekm

@swiatekm swiatekm merged commit f9eb06f into 8.x Feb 25, 2025
14 checks passed
@swiatekm swiatekm deleted the mergify/bp/8.x/pr-6697 branch February 25, 2025 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants