-
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
Fix erroneously created http url directory path for monitoring #1811
Fix erroneously created http url directory path for monitoring #1811
Conversation
@@ -75,7 +76,7 @@ func exposeMetricsEndpoint( | |||
} | |||
|
|||
func createAgentMonitoringDrop(drop string) error { | |||
if drop == "" || runtime.GOOS == "windows" { | |||
if drop == "" || runtime.GOOS == "windows" || isHttpUrl(drop) { |
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.
This looks like it fixes it, but why is an HTTP URL even being passed here?
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.
@blakerouse do you know the history on this? seems like the monitoring changed from http to the local socket
between V1 and V2?
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.
Approving so we don't have a random http URL in our directory tree on installs, which looks a bit embarrassing. We can figure out where this is coming from separately.
🌐 Coverage report
|
/test |
* Fix erroneously created http url directory path for monitoring * Add changelog (cherry picked from commit 4ca690a)
#1825) * Fix erroneously created http url directory path for monitoring * Add changelog (cherry picked from commit 4ca690a) Co-authored-by: Aleksandr Maus <[email protected]>
What does this PR do?
Fixes erroneously created http url directory path for monitoring when the agent runs.
Added a check if the url is passed in the path.
Why is it important?
No erroneous directories should be created during the agent execution.
Checklist
How to test this PR locally
/Library/Elastic/Agent/http\:/localhost\:6791