You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Recently I sent a small patch so that the User-Agent would be sent to in_prometheus_scraper HTTP request, but then I thought that this could be the default behavior for every HTTP requests from fluent-bit.
I'll try to map on this issue all the places we could have this added, and if it's of interest of the maintainers, I can start working on PRs to tackle each of them individually.
Proposal
According to HTTP reference from Mozilla1, we should have something like:
And then, from inside each plugin/module before calling flb_http_do we call a flb_http_enrich_user_agent (or a better name) that would receive a ex.: (input: in_prometheus_scrape) part to be added, and ending like:
endersonmaia
changed the title
Properly formated User-Agent should be send in all HTTP Requests
Properly formated User-Agent should be sent in all HTTP Requests
May 30, 2024
Recently I sent a small patch so that the
User-Agent
would be sent toin_prometheus_scraper
HTTP request, but then I thought that this could be the default behavior for every HTTP requests from fluent-bit.I'll try to map on this issue all the places we could have this added, and if it's of interest of the maintainers, I can start working on PRs to tackle each of them individually.
Proposal
According to HTTP reference from Mozilla1, we should have something like:
User-Agent: Fluent-Bit/3.0.6 (input: prometheus_scrape, Git commit: 9af65e2c36a2c36e75b93cab6a92bf29c307ec9e)
Where to add this change
Ideally, we should have a well formed User-Agent like:
User-Agent: Fluent-Bit/3.0.6 (input: in_prometheus_scrape, Git commit: 9af65e2c36a2c36e75b93cab6a92bf29c307ec9e)
And that would change based on the plugin used to make the requests.
Originally posted by @endersonmaia in #8880 (comment)
Footnotes
https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent ↩
The text was updated successfully, but these errors were encountered: