Repository navigation
http_config: add Prometheus HTTPClientConfig and reqwest client builder - #44
Merged
Merged
Conversation
This was referenced Nov 10, 2026
bwplotka
force-pushed
the
bwplotka/http-config
branch
from
November 18, 2026 05:37
ed9f909 to
49fb2e6
Compare
bwplotka
marked this pull request as ready for review
November 18, 2026 06:13
saswatamcode
approved these changes
Nov 18, 2026
saswatamcode
left a comment
Member
There was a problem hiding this comment.
Generally seems great, some combined human + AI comments.
bwplotka
commented
Nov 19, 2026
bwplotka
left a comment
Member
Author
There was a problem hiding this comment.
Thanks for solid review! Addresed
…eader checks Signed-off-by: Bartek Plotka <bwplotka@gmail.com>
…ock extraction Signed-off-by: Bartek Plotka <bwplotka@gmail.com>
…action tests Signed-off-by: Bartek Plotka <bwplotka@gmail.com>
bwplotka
force-pushed
the
bwplotka/http-config
branch
from
November 19, 2026 10:57
b52fd55 to
095233e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds the standalone
http-configCargo feature andexpfmt::http_configmodule implementing PrometheusHTTPClientConfigschema parsing, validation,set_directory, secret redaction inDebugandSerialize, andreqwest(rustls+http2) client and request builders reusable across HTTP service discovery and scraping. Part of prometheus/scrape.rs#36.Stack:
discovery: add TargetGroup, StaticConfig, and Prometheus duration helpersdiscovery/dns: add DNS service discovery (dns_sd_configs)http_config: add Prometheus HTTPClientConfig and reqwest client builder(this PR)discovery/kubernetes: add pod service discovery (role: pod)Commits in reading order:
http_config: add Prometheus HTTPClientConfig schema, validation, and secret redactionhttp_config: add reqwest client builder, header injection, and HTTPS mTLS testsIntentional differences from Go
HttpClientConfigbuilds areqwest::Clientbacked byrustlsrather than wrapping Gonet/http.RoundTrippermiddleware as in config/http_config.go#L604.oauth2in config/http_config.go#L239, external secret manager*_reffields in config/http_config.go#L505,tls_config.server_namein config/http_config.go#L1305-L1306, and combiningproxy_from_environmentwithproxy_connect_headerin config/http_config.go#L1687-L1692 are parsed and validated for config compatibility, and returnHttpConfigError::InvalidConfigat client build or request time until runtime support is wired.