Skip to content

[Infra] Indexer event-processing failures are only logged - no failed-event counter in /health or admin metrics #844

Description

@grantfox-oss

Telegram (ask questions / claim the issue here first): https://t.me/+DOylgFv1jyJlNzM0

Why this matters

soroban-event-worker.ts:247-253 swallows per-event errors with logger.error and continues; there is no eventsProcessed/eventsFailed counter. /health only reports DB status and indexer lag (which stays low because the upsert bumps updatedAt every poll), and admin metrics report only lastLedger/lagSeconds. So an indexer silently dropping every event looks perfectly healthy.

Acceptance criteria

  • Maintain eventsProcessed / eventsFailed / lastErrorAt counters in the worker
  • Expose them in GET /v1/admin/metrics.indexer and consider a degraded signal when failures spike
  • Cover the new counters with a unit test

Files to touch

  • backend/src/workers/soroban-event-worker.ts
  • backend/src/routes/v1/admin.routes.ts
  • backend/src/routes/health.routes.ts

Out of scope

  • Adding a Prometheus exposition format endpoint

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programbackendBackend related tasksdevopsInfrastructure and CI/CDenhancementNew feature or requestinfraCI/CD and infrastructure

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions