FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[!] add OpenTelemetry tracing and metrics support by pashagolub · Pull Request #768 · cybertec-postgresql/pg_timetable · GitHub

[!] add OpenTelemetry tracing and metrics support - #768

Merged
pashagolub merged 3 commits into
masterfrom
add-otel
Jun 22, 2026
Merged

pashagolub merged 3 commits into
masterfrom
add-otel

Conversation

Copy link
Copy Markdown
Collaborator
  • Add OTelOpts config struct
  • Add internal/otel package: Provider, Tracer, Meter, Shutdown, Noop
  • Add 5 metric instruments
  • Instrument executeChain and executeTask with spans and metrics
  • Wire real provider in main.go with graceful shutdown
  • ValidateOTel() validates endpoint scheme, ratio, and timeouts
  • Protocol auto-detected from URL scheme (grpc:// vs http(s)://)
  • Headers are YAML-only (prevents secrets in shell history)
  • Fallback to Noop provider on init failure

pashagolub self-assigned this Jun 10, 2026
pashagolub added enhancement New feature or request documentation Good for newcomers epic Large body of work broken down into a number of smaller issues labels Jun 10, 2026

coveralls commented Jun 10, 2026
edited
Loading

Copy link
Copy Markdown

Coverage Report for CI Build 27977604711

Coverage decreased (-0.2%) to 89.606%

Details

  • Coverage decreased (-0.2%) from the base build.
  • Patch coverage: 33 uncovered changes across 5 files (236 of 269 lines covered, 87.73%).
  • No coverage regressions found.

Uncovered Changes

File Changed Covered %
internal/otel/otel.go 139 127 91.37%
internal/otel/metrics.go 59 49 83.05%
main.go 13 8 61.54%
internal/config/config.go 23 19 82.61%
internal/scheduler/chain.go 33 31 93.94%
Total (6 files) 269 236 87.73%

Coverage Regressions

No coverage regressions found.


Coverage Stats

Relevant Lines: 2261
Covered Lines: 2026
Line Coverage: 89.61%
Coverage Strength: 1.02 hits per line

💛 - Coveralls

0xgouda left a comment
edited
Loading

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

I am testing this and noticed that there are no INFO log messages for metrics/traces collection or upload, which in my opinion is nice to have to be able to confirm that things are working as expected and maybe help in deubgging in some scenarios.

0xgouda left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Thinking Out Loud: How can one configure 2 different endpoints, one for trace exportation and one for metrics?

Copy link
Copy Markdown
Collaborator Author

no INFO log messages for metrics/traces collection or upload

What? In what way log messages are connected to metrics and traces? What am I missing here?

- Add `OTelOpts` config struct
- Add `internal/otel` package: Provider, Tracer, Meter, Shutdown, Noop
- Add 5 metric instruments
- Instrument `executeChain` and `executeTask` with spans and metrics
- Wire real provider in `main.go` with graceful shutdown
- `ValidateOTel()` validates endpoint scheme, ratio, and timeouts
- Protocol auto-detected from URL scheme (grpc:// vs http(s)://)
- Headers are YAML-only (prevents secrets in shell history)
- Fallback to `Noop` provider on init failure
pashagolub merged commit 4126d4e into master Jun 22, 2026
6 checks passed
pashagolub deleted the add-otel branch June 22, 2026 19:21
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

Labels

documentation Good for newcomers enhancement New feature or request epic Large body of work broken down into a number of smaller issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL