Skip to content

feat(backend-sep24): [sep-24] log detailed interaction metrics to prometheus#665

Open
GideonBature wants to merge 1 commit into
ceejaylaboratory:mainfrom
GideonBature:prometheus
Open

feat(backend-sep24): [sep-24] log detailed interaction metrics to prometheus#665
GideonBature wants to merge 1 commit into
ceejaylaboratory:mainfrom
GideonBature:prometheus

Conversation

@GideonBature

Copy link
Copy Markdown
Contributor

Summary

Adds SEP-24–specific Prometheus metrics for interactive endpoint request duration and volume.

  • Registers sep24_interaction_requests_total and sep24_interaction_endpoint_duration_seconds on the shared metrics registry
  • Adds sep24MetricsMiddleware to record endpoint, method, status code, and duration on response finish
  • Applies middleware to all /sep24 routes (deposit and withdraw interactive endpoints)
  • Adds unit tests for metric registration and recording

Closes #618

Test plan

  • npm test -- --testPathPattern="sep24-metrics"
  • npm test -- --testPathPattern="sep24.route"
  • npm run build (fails on pre-existing TS errors in unrelated files: queue-dashboard.route.ts, multisig.service.ts, sep31CallbackNotifier.ts)
  • Hit POST /sep24/transactions/deposit/interactive and POST /sep24/transactions/withdraw/interactive, then confirm metrics appear at GET /metrics:
    • sep24_interaction_requests_total{endpoint="...",method="POST",status_code="..."}
    • sep24_interaction_endpoint_duration_seconds{endpoint="...",method="POST",status_code="..."}

@drips-wave

drips-wave Bot commented Jun 26, 2026

Copy link
Copy Markdown

@GideonBature Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[SEP-24] Log Detailed Interaction Metrics to Prometheus

1 participant