-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[chore] [receiver/simpleprometheus] Use confighttp.NewDefaultClientConfig instead of manually creating struct #35652
[chore] [receiver/simpleprometheus] Use confighttp.NewDefaultClientConfig instead of manually creating struct #35652
Conversation
…nfig instead of manually creating struct **Description:** This PR makes usage of `NewDefaultClientConfig` instead of manually creating the confighttp.ClientConfig struct. **Link to tracking Issue:** open-telemetry#35457
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
@fatsheep9146 can you please take a look ? |
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
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 think integration test is broken, could you please check this?
=== FAIL: . TestGetPrometheusConfigWrapper/Test_TLSEnable_false_but_tls_configured (re-run 1) (0.00s)
receiver_test.go:437:
Error Trace: /home/runner/work/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/simpleprometheusreceiver/receiver_test.go:437
Error: Not equal:
expected: &prometheusreceiver.Config{PrometheusConfig:(*prometheusreceiver.PromConfig)(0xc00057e788), TrimMetricSuffixes:false, UseStartTimeMetric:false, StartTimeMetricRegex:"", ReportExtraScrapeMetrics:false, TargetAllocator:(*targetallocator.Config)(nil)}
actual : &prometheusreceiver.Config{PrometheusConfig:(*prometheusreceiver.PromConfig)(0xc00057ec88), TrimMetricSuffixes:false, UseStartTimeMetric:false, StartTimeMetricRegex:"", ReportExtraScrapeMetrics:false, TargetAllocator:(*targetallocator.Config)(nil)}
Diff:
--- Expected
+++ Actual
@@ -48,3 +48,3 @@
MetricsPath: (string) (len=7) "/metric",
- Scheme: (string) (len=5) "https",
+ Scheme: (string) (len=4) "http",
EnableCompression: (bool) false,
…mackjmr/opentelemetry-collector-contrib into use-newdefault-simpleprometheusreceiver
@open-telemetry/collector-contrib-maintainers Could any maintainers help merge this pr please? Thanks! |
Description:
This PR makes usage of
NewDefaultClientConfig
instead of manually creating the confighttp.ClientConfig struct.Link to tracking Issue: #35457