Commit Graph
472 Commits
Author SHA1 Message Date
Marc Schäfer f455db0f73 Add WebSocket and proxy lifecycle metrics
Former-commit-id: d21f4951e98318631069a2fd69453683bf96fa42
2025-10-10 19:15:33 +02:00
Marc Schäfer 32c3c8373c Merge pull request #9 from marcschaeferger/dependabot/go_modules/prod-minor-updates-8fc2d76c77
Bump the prod-minor-updates group across 1 directory with 4 updates

Former-commit-id: e04c654292cd9b05c5bac43a904b767cdc5202f5
2025-10-10 18:21:31 +02:00
Marc Schäfer 325a7f1418 Merge pull request #10 from marcschaeferger/codex/review-opentelemetry-metrics-and-tracing
Enhance telemetry metrics and context propagation

Former-commit-id: e43fbebcb8797cde95b9dc3c260efbae81f529d6
2025-10-10 18:21:14 +02:00
Marc Schäfer d4b37610f6 Merge branch 'main' into codex/review-opentelemetry-metrics-and-tracing
Former-commit-id: 1afed3256276291afb1e3bfa6aa79207c9090a60
2025-10-10 18:20:41 +02:00
Marc Schäfer 4bc9ba6178 fix(metrics): update metrics recommendations and add OpenTelemetry review documentation
Former-commit-id: 46384e6242b7036180ade82c936c3d3ab4a2500d
2025-10-10 18:18:38 +02:00
Marc Schäfer ede06c9e22 Enhance telemetry metrics and context propagation
Former-commit-id: 52e4a57cc1060acd12226696ab27003f4d6a5b4a
2025-10-10 18:17:59 +02:00
Marc Schäfer 7e9e5348cf fix(github-actions): add permissions section for content read access in workflows
Former-commit-id: 1a9f6c46852e28c319fbaf1170757bb6169eec4f
2025-10-10 15:34:00 +02:00
Marc Schäfer 0b729e6d8c fix(telemetry): enhance session observation logic for tunnel IDs and site-level aggregation
Former-commit-id: b6f5458ad995a2e8efe332adc614ccce1c578745
2025-10-10 15:30:06 +02:00
Marc Schäfer 50681f9da2 fix(observability): enhance clarity and structure of metrics documentation
Former-commit-id: 4ef9737862a307ea4baf80d442da4957a5a29785
2025-10-10 15:29:53 +02:00
Marc Schäfer db4ebb9fa8 fix(prometheus): clarify instructions regarding scraping the Collector
Former-commit-id: b68777e83aaa4834158dfa7791983d4f0cdeb138
2025-10-10 15:29:45 +02:00
Marc Schäfer 57e092f02b fix(docker-compose): improve comments for clarity on port mapping and collector usage
Former-commit-id: 8d26de5f4da731181231327cca1135f0ad56773d
2025-10-10 15:29:24 +02:00
Marc Schäfer 99b8630fa1 fix(readme): enhance clarity and structure of installation and documentation sections
Former-commit-id: c32828128f7a7efc7da44b2d3ff49b6f6f4da9c1
2025-10-10 14:49:14 +02:00
Marc Schäfer 664cf5dadd fix(prometheus): update comment for clarity and consistency in scraping instructions
Former-commit-id: 3cd7329d8bb83c660ea4f3cd7c48cda9f7c96437
2025-10-10 14:47:49 +02:00
Marc Schäfer 3e753c0848 fix(docker-compose, prometheus): remove unnecessary comments and improve clarity
Former-commit-id: 34902208032df5e662f78fdd9fdd37a95a3e6255
2025-10-10 14:46:17 +02:00
Marc Schäfer 495ff18366 fix(docker-compose, prometheus, telemetry, proxy): standardize collector naming and improve error handling
Former-commit-id: bd62da4cc9f780cf254eb5aeb770f14308d5c529
2025-10-10 14:42:05 +02:00
Marc Schäfer 6bddd8ea01 fix(metrics): enhance documentation clarity and structure for metrics recommendations
Former-commit-id: 8d0e6be2c703acce1ef9fe40b4cc6c9a96aef88c
2025-10-10 14:17:24 +02:00
Marc Schäfer d01a1316c7 fix(manager, stub, util): enhance error handling and logging consistency
Former-commit-id: b62e18622e0f428d1ab88b887d85ee207c433f22
2025-10-10 14:16:28 +02:00
dependabot[bot] ccae31de7a Bump the prod-minor-updates group across 1 directory with 4 updates
Bumps the prod-minor-updates group with 3 updates in the / directory: [go.opentelemetry.io/otel/exporters/prometheus](https://github.com/open-telemetry/opentelemetry-go), [golang.org/x/crypto](https://github.com/golang/crypto) and [google.golang.org/grpc](https://github.com/grpc/grpc-go).


Updates `go.opentelemetry.io/otel/exporters/prometheus` from 0.57.0 to 0.60.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-go/releases)
- [Changelog](https://github.com/open-telemetry/opentelemetry-go/blob/main/CHANGELOG.md)
- [Commits](https://github.com/open-telemetry/opentelemetry-go/compare/exporters/prometheus/v0.57.0...exporters/prometheus/v0.60.0)

Updates `golang.org/x/crypto` from 0.42.0 to 0.43.0
- [Commits](https://github.com/golang/crypto/compare/v0.42.0...v0.43.0)

Updates `golang.org/x/net` from 0.44.0 to 0.45.0
- [Commits](https://github.com/golang/net/compare/v0.44.0...v0.45.0)

Updates `google.golang.org/grpc` from 1.75.1 to 1.76.0
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.75.1...v1.76.0)

---
updated-dependencies:
- dependency-name: go.opentelemetry.io/otel/exporters/prometheus
  dependency-version: 0.60.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: prod-minor-updates
- dependency-name: golang.org/x/crypto
  dependency-version: 0.43.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: prod-minor-updates
- dependency-name: golang.org/x/net
  dependency-version: 0.45.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: prod-minor-updates
- dependency-name: google.golang.org/grpc
  dependency-version: 1.76.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: prod-minor-updates
...

Signed-off-by: dependabot[bot] <support@github.com>
Former-commit-id: 89274eb9a8e721b9fbc7cc197541f476ff906799
2025-10-09 09:41:55 +00:00
Marc Schäfer 54599899dd fix(wgtester): improve logging format for consistency and clarity
Former-commit-id: 77d56596ab370e4f210bd497d7ba1f8c20c2e3dd
2025-10-08 08:14:35 +02:00
Marc Schäfer fb3f7ab29f fix(main): refactor logging messages and introduce constants for improved readability
Former-commit-id: 6ec0ab813c0f1cfa4d1104bc7cd2837363715d8f
2025-10-08 08:14:25 +02:00
Marc Schäfer 0c3de24b2b fix(websocket): improve error type handling in connection establishment and ping monitoring
Former-commit-id: fef9e8c76b313dd13d6a9ec32832ce2fe6191de2
2025-10-08 08:14:04 +02:00
Marc Schäfer d09ae97d67 fix(sonar-telemetry): update observeSessionsFor function to include siteID and improve attribute handling
Former-commit-id: ae5129a7c73900a16b8907e2e859dd13cacc3382
2025-10-08 08:13:35 +02:00
Marc Schäfer c364ba0a0b fix(docker-compose): update comments in metrics configuration for clarity and consistency
Former-commit-id: ed127a2d612aa1ce26b1464a626c769709a03f65
2025-10-08 08:12:58 +02:00
Marc Schäfer 20fa84208d fix(telemetry): update proxyStopper to be a no-op function when registration fails
Former-commit-id: 20ddbb53823b1a66031a2844b98f0e151dc2644b
2025-10-08 08:12:20 +02:00
Marc Schäfer c5e25d7c36 fix(docker-compose): update newt service configuration to use local build and environment file
Former-commit-id: 5cbda356372c074f77623576b3ad8d4e71307613
2025-10-08 07:34:27 +02:00
Marc Schäfer afe687c781 fix(telemetry): improve error handling and formatting in telemetry setup functions
Former-commit-id: 60196455d1526626a641b3ba63add3314f289383
2025-10-08 07:33:11 +02:00
Marc Schäfer 5071489fae docs(observability): update code blocks to specify language for better syntax highlighting
Former-commit-id: 84e659acdeb2316b3c58815d9cd76872c650447c
2025-10-08 01:12:51 +02:00
Marc Schäfer 9d62e2d110 fix(sonar): SetObservableCallback uses unregister stopper instead of empty function to satisfy S1186
Former-commit-id: e16881b7c87a3666c68d668969f947ed3442cc59
2025-10-08 01:09:18 +02:00
Marc Schäfer 221db4709b fix(build): use Registration.Unregister() without context; return tracer shutdown func from setupTracing
Former-commit-id: 587e829e42a8112f1205dd3c468504887b1c4887
2025-10-08 01:07:08 +02:00
Marc Schäfer 166335b30d refactor(telemetry): reduce cognitive complexity by splitting registerInstruments and Init; add unregister stoppers; extract state_view helpers
Former-commit-id: ee2f8899ff545abba1f6e37fc9ed240f9311ff0a
2025-10-08 01:06:13 +02:00
Marc Schäfer 781ab23aef docs(README): add Observability Quickstart section and link to docs/observability.md
Former-commit-id: 744a74155610529e339b60d5d59a8217524bbd01
2025-10-08 01:01:33 +02:00
Marc Schäfer 38b52b0fbd docs: add Quickstart in observability; examples: add docker-compose.metrics.collector.yml and prometheus.with-collector.yml (collector-only scrape)
Former-commit-id: aea80200e002a31e60ba94da551411804b2d8db3
2025-10-08 00:58:30 +02:00
Marc Schäfer 9db7da4426 feat(metrics): NEWT_METRICS_INCLUDE_TUNNEL_ID toggle; conditionally drop tunnel_id across bytes/sessions/proxy/reconnect; docs and smoke test updated; examples/prometheus.yml with relabels; docker-compose defaults avoid double-scrape
Former-commit-id: b20f7a02b2fe861d27111f8c7716a225866ee025
2025-10-08 00:53:40 +02:00
Marc Schäfer 9f682c3a5f fix(telemetry): adapt to RegisterCallback returning (Registration, error)
Former-commit-id: f28d90595ba47cbb54c3b8a1515da7cd0c47400f
2025-10-08 00:46:41 +02:00
Marc Schäfer 7f6d518604 docs+examples: document direction=ingress|egress, initiator and error_type enums; add cardinality relabel tips; provide Collector variants; add scripts/smoke-metrics.sh
Former-commit-id: 4a90e36a442afbb46fe3c027eae205d11bf02d62
2025-10-08 00:46:01 +02:00
Marc Schäfer eb87b24d13 fix(metrics): direction=ingress|egress for bytes; remove transport on tunnel_sessions; extend allow-list (msg_type, phase); add units for histograms and bytes; handle callback errors; normalize error_type taxonomy; HTTP error mapping to enums
Former-commit-id: 9ace45e71f388477d493eb87d9b9758d4a43290e
2025-10-08 00:43:53 +02:00
Marc Schäfer 967e8e6e4b fix: update IncReconnect for auth failures; import metric in proxy manager for observable callback
Former-commit-id: 75d5e695d623fe292acceb586d2ecd6fb0052308
2025-10-08 00:32:39 +02:00
Marc Schäfer 61489d46cd feat(phase2): websocket connect latency and message counters; proxy active/buffer/drops gauges and counters; config apply histogram; reconnect initiator label; update call-sites
Former-commit-id: d74065a71b0b9558caeab5ede4bc0c05a483692e
2025-10-08 00:30:07 +02:00
Marc Schäfer 0e4e2a6ca2 docs: update observability catalog to include site_id labels and clarify transport vs protocol; add METRICS_RECOMMENDATIONS.md with roadmap and ops guidance
Former-commit-id: f86031f4583575fe885ddab8eeeff6477802b47c
2025-10-08 00:10:54 +02:00
Marc Schäfer 0c51a6d498 test(telemetry): assert allowed attribute site_id appears in metrics exposition
Former-commit-id: 31f70e50320ada1b37044158d8cbfe48d9748391
2025-10-08 00:10:17 +02:00
Marc Schäfer ab83c071f8 feat(proxy): add site_id (and optional region) to bytes attribute sets for tunnel metrics
Former-commit-id: 31514f26df6684b3b7359951754ef49e5f2e5994
2025-10-08 00:10:03 +02:00
Marc Schäfer f9b824d227 fix(main): remove duplicate ClearTunnelID/State and call telemetry.UpdateSiteInfo after resolving client ID
Former-commit-id: 09fcb369633f3b3e69ba666514c8477aa7d8cd4d
2025-10-08 00:09:44 +02:00
Marc Schäfer cbc7931bc4 feat(telemetry/state_view): add site_id label to gauges and set tunnel_sessions transport=wireguard (no hardcoded tcp)
Former-commit-id: 83c3ae5cf950416fe4d72ba8ead309c183487a21
2025-10-08 00:09:30 +02:00
Marc Schäfer 3461fe2e09 feat(telemetry,metrics): allow site_id/region in attribute filter; read site_id from NEWT_SITE_ID/NEWT_ID or OTEL_RESOURCE_ATTRIBUTES; propagate site_id/region labels across metrics; include site labels in build_info; seed global site info
Former-commit-id: 1e88fb86b40ec6c774a8f1a7e7f01ddad8787ffc
2025-10-08 00:09:17 +02:00
Marc Schäfer f6be21c816 remove: removed test results
Former-commit-id: 62407b0c740168623a8b27d4f71c357954d225e5
2025-10-08 00:02:44 +02:00
Marc Schäfer 7d62b6ceb3 fix: Update observability documentation to correct code block syntax and improve clarity
Former-commit-id: d91c6ef1689922799125d25db8ac841f41ff3fd6
2025-10-08 00:00:56 +02:00
Marc Schäfer 27342ddf18 chore: Update docker-compose.metrics.yml for improved service configuration
Former-commit-id: 59e8d79404f57428ecf2f38111b685c3608238e5
2025-10-07 23:55:47 +02:00
Marc Schäfer 8e2f2b5acb fix: Remove unnecessary blank line in prometheus.yml
Former-commit-id: d907ae9e84637cd8976915983c5734f7d96acb7a
2025-10-07 23:55:23 +02:00
Marc Schäfer c03f64a524 feat: Add Grafana dashboard and Prometheus datasource configuration files
Former-commit-id: d745aa79d4c0873c709d31aade0fc510f8198b7b
2025-10-07 18:45:40 +02:00
Marc Schäfer 20068aa974 fix: Update observability documentation to clarify resource attributes and scraping strategy
Former-commit-id: 427ab67bb5391670092669f482a2859f9e493cc5
2025-10-07 18:45:02 +02:00