Skip to content

Conversation

cdupuis
Copy link
Contributor

@cdupuis cdupuis commented Oct 8, 2025

Proposed changes

This PR fixes an error condition that seems to have been introduced in cbaa068.

Tests

Following the tests from #979, I see the following error which is consistent with the error condition:

./nginx-prometheus-exporter \
  --nginx.proxy-protocol \
  --nginx.scrape-uri="http://127.0.0.1:18080/stub_status" \
  --web.listen-address=":9116" \
  --web.telemetry-path="/metrics"
time=2025-10-08T08:50:46.977+02:00 level=INFO source=exporter.go:126 msg=nginx-prometheus-exporter version="(version=, branch=, revision=064e74611406c672b3c2403bcdd55cd24d47876d-modified)"
time=2025-10-08T08:50:46.978+02:00 level=INFO source=exporter.go:127 msg="build context" build_context="(go=go1.25.0, platform=darwin/arm64, user=, date=, tags=unknown)"
time=2025-10-08T08:50:46.979+02:00 level=INFO source=tls_config.go:346 msg="Listening on" address=[::]:9116
time=2025-10-08T08:50:46.979+02:00 level=INFO source=tls_config.go:349 msg="TLS is disabled." http2=false address=[::]:9116
time=2025-10-08T08:51:17.609+02:00 level=ERROR source=nginx.go:57 msg="error getting stats" error="failed to get http://127.0.0.1:18080/stub_status: Get \"http://127.0.0.1:18080/stub_status\": round trip failed: writing proxyproto header via tcp to 127.0.0.1:18080: %!w(<nil>)"

With the change in this PR I can successfully run through the series of tests outlined in #979.

Checklist

Before creating a PR, run through this checklist and mark each as complete.

  • I have read the CONTRIBUTING guide
  • I have proven my fix is effective or that my feature works
  • I have checked that all unit tests pass after adding my changes
  • I have ensured the README is up to date
  • I have rebased my branch onto main
  • I will ensure my PR is targeting the main branch and pulling from my branch on my own fork

@cdupuis cdupuis requested a review from a team as a code owner October 8, 2025 06:53
Copy link

nginx-bot bot commented Oct 8, 2025

Hi @cdupuis! Welcome to the project! 🎉

Thanks for opening this pull request!
Be sure to check out our Contributing Guidelines while you wait for someone on the team to review this.

@nginx-bot nginx-bot bot added the community Issues or PRs opened by an external contributor label Oct 8, 2025
Copy link

github-actions bot commented Oct 8, 2025

✅ All required contributors have signed the F5 CLA for this PR. Thank you!
Posted by the CLA Assistant Lite bot.

@github-actions github-actions bot added the bug An issue reporting a potential bug label Oct 8, 2025
@cdupuis
Copy link
Contributor Author

cdupuis commented Oct 8, 2025

I have hereby read the F5 CLA and agree to its terms

@pdabelf5 pdabelf5 merged commit b81e3a8 into nginx:main Oct 13, 2025
13 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug An issue reporting a potential bug community Issues or PRs opened by an external contributor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants