-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't run any agent service when running otel
subcommand
#5748
Conversation
Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane) |
This pull request does not have a backport label. Could you fix it @blakerouse? 🙏
|
|
Quality Gate failedFailed conditions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, but it'd be good for @andrzej-stencel to have a look at this as well, imo.
@@ -463,22 +426,6 @@ func TestOtelAPMIngestion(t *testing.T) { | |||
) | |||
require.NoError(t, err, "APM not initialized") | |||
|
|||
// wait for otel collector to start |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it worth replacing this with a check of the upstream health endpoint?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think its worth it at the moment. The work I am doing in #5767 will expose status information over the elastic-agent status
command again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this as a simplification now that the direction we are going with elastic-agent is clearer than it was when the otel
command was first implemented.
Once #5767 is implemented we can probably remove the elastic-agent otel
command entirely.
I think it depends on if we want a true 100% otel implementation or something that has some of the Elastic Agent code running. I think the longer term goal is to make the |
Force merging to get around the failed SonarQube check. |
* Remove need to run agent while running otel subcommand. * Cleanup. * Fix tests. * Fix tests. * Few more cleanups. * Mage check. (cherry picked from commit 3f1e4da)
What does this PR do?
Previously the control protocol was started when the subcommand
otel
was ran. This should not be done as the subcommandotel
should operate it in a pure OTel mode.This is a cleanup that comes out of working on Hybrid mode.
Why is it important?
Cleanup to make the code cleaner and less messy as the control protocol should not really be running when running the otel subcommand.
Checklist
[ ] I have made corresponding changes to the documentation[ ] I have made corresponding change to the default configuration files[ ] I have added an entry in./changelog/fragments
using the changelog toolDisruptive User Impact
Can no longer call
elastic-agent status
when aelastic-agent otel
is running.How to test this PR locally
Run
elastic-agent otel
, then try to runelastic-agent status
and see that it doesn't connect.