Skip to content

Sentry SDK integration + enriched health check #3317

Description

@PierreBrisorgueil

Phase 5 — Logging & Monitoring (3/3)

What

  • Add @sentry/node dependency
  • New lib/services/sentry.js — init function, exports Sentry error handler
  • Mount Sentry error handler after routes in express.js
  • Enrich existing /api/health endpoint: DB status, uptime, version, memory usage
  • Config-driven: no-op when DSN is empty

Config

sentry: { dsn: '', environment: 'development', enabled: false }

Acceptance

  • Sentry captures unhandled exceptions and request errors
  • Sentry requestHandler adds context (user, tags)
  • Health endpoint returns { status, db, uptime, version, memory }
  • No-op when sentry.enabled: false or DSN empty

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions