Skip to content
This repository was archived by the owner on Aug 11, 2026. It is now read-only.
This repository was archived by the owner on Aug 11, 2026. It is now read-only.

feat(observability): add metrics, SLOs, job health, and provider telemetry #698

Description

@ahliweb

Parent epic: #679
Related logging foundation: #447

Objective

Add provider-neutral, privacy-safe operational signals for the web runtime, database pool, background jobs, and optional external providers.

Scope

  • Define a small metrics port with no-op/default implementation.
  • Add low-cardinality counters/histograms/gauges for request outcomes/latency, pool saturation, job run status/backlog, and provider outcome/latency/circuit state.
  • Define initial SLIs/SLOs and burn-rate/threshold guidance.
  • Add authorized health/readiness output that distinguishes local dependencies from optional online providers.
  • Document Prometheus/OpenTelemetry adapter examples as optional integrations.
  • Add dashboard/runbook examples without coupling core runtime to a SaaS.

Guardrails

  • No tenant IDs, routes with unbounded IDs, email/IP, object keys, tokens, prompts, or conversation content in labels.
  • Offline/LAN operation works with no external collector.
  • Metrics must not be used as an authorization source.

Acceptance criteria

  • Metric names/labels have documented cardinality and privacy review.
  • Job/provider failure and recovery are observable.
  • SLOs map to actionable runbooks.
  • Unit tests cover no-op and representative adapter behavior.
  • Load/smoke test proves metrics do not materially degrade request processing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:architectureStruktur repo, module contract, registryarea:loggingStructured logging, audit trailpriority:p2Prioritas sedang - opsional/provider-dependenttype:featureFitur baru sesuai doc 06

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions