DEVELOPER GUIDE

Operational reports

Inspect measured time series across replicas without confusing publication with delivery.

Sync health

Open Sync health in the administrator dashboard. Choose an hour, day, week or 30-day window and optionally a replica. Counters compare the selected window with the equally sized preceding window. Click a chart point or inspect its table row for exact interval values. Times are stored in UTC and displayed in your browser's timezone.

The API records publication attempts, failed outbox drains and authenticated socket connections/disconnections in MongoDB minute buckets. Charts use minute buckets for one hour/day and hourly buckets for longer windows. Latency histograms merge counts across replicas before calculating the p95 bucket upper bound. The finite upper bounds are 10, 50, 100, 250, 500, 1,000, 5,000, 15,000 and 60,000 milliseconds. A p95 in the overflow bucket is unavailable rather than falsely capped at 60 seconds.

The pending-event count and oldest pending age are sampled once per minute. A unique MongoDB minute claim lets only one replica scan shared state; a failed sampler leaves a gap until the next minute. These are shared cluster snapshots even when a replica filter is selected; they are never summed once per replica. Hourly charts show the last recorded snapshot in each hour.

Interpretation and retention

  • Publication latency measures MongoDB mutation time to successful publication, including queue delay. With Redis this follows its AOF acknowledgement; without Redis it measures local emit. It is not acknowledgement from an application client.
  • Publication attempts can include duplicate event IDs after a worker crash.
  • Failed drain counts include database/lease errors as well as publication errors; they are not a count of uniquely failed events.
  • Metrics are best-effort: a process crash or database outage can lose telemetry even though the transactional data/outbox remains durable. Gaps are not zero traffic.
  • Metrics and snapshots expire after 90 days. No historical traffic is fabricated or backfilled. An idle installation can have no event samples.
  • The administrator-only GET /api/v1/admin/reports/health accepts hours (1, 24, 168, 720), optional ISO end (past 60 days), and replica. Queries have bounded windows and a database execution timeout.

No separate monitoring service is required. All replicas must share MongoDB and have synchronized clocks. Reports contain counts and identifiers, never API-key secrets or stored JSON values. The dashboard refreshes each minute and reports errors instead of replacing failed reads with zeroes.

Usage and quotas

Open Usage & quotas and filter by project ID or API-key record ID (never paste the secret). Read/write admissions include HTTP requests, Socket.IO handshakes and operations, matching the existing quota enforcement path. Administrator traffic is excluded. Completed HTTP responses, HTTP errors and HTTP 429 responses have separate charts; they must not be added to admissions as if they were distinct requests.

The existing quota gate returns HTTP 403 when exhausted or concurrently disabled; the Quota / disabled rejections chart counts that outcome explicitly. Failed authentication and requests rejected before the quota gate are not attributed to a key. The dashboard does not silently relabel 403 responses as 429.

Click a traffic point or inspect an interval to investigate a spike. Top consumers show the 50 keys with most admissions in the selected window; clicking a key filters the report. Enter a specific key ID to inspect an idle key's quotas.

Quota cards use live database counters and UTC reset markers, treating counters from expired windows as zero. Minute, hour, day and calendar-month limits show the next reset. Estimated exhaustion uses the average consumption since the current window started; it is only shown if that rate would reach the limit before reset. Sparse traffic, a recent rollout and bursts reduce forecast usefulness. Unlimited quotas have no exhaustion estimate. These cards show current quotas even when viewing a historical traffic window.

GET /api/v1/admin/reports/usage accepts the same time-range parameters plus project and apiKeyId. Live quotas only cover the returned top 50 keys, or the explicitly selected key. Metrics share the 90-day best-effort retention policy.

Changes and growth

Open Changes & growth to compare creations, updates, deletions and restores with the preceding period. Filter by project. Change events are recorded in the same MongoDB transaction as the storage mutation and outbox entry, so rollback leaves no event and an idempotent retry adds no duplicate. Restoring a value counts as one restore instead of an additional update. A delete or restore that changes nothing does not count as a new revision. Counts start after installing this release; old history snapshots are not misclassified as new mutations.

Conflicts count retained conflict records by creation time. The top 50 changed keys group equal key names within each project, across users. No values or credentials are returned. Change-event metadata is retained for 90 days independently of the history snapshot retention setting.

Storage growth is sampled by project each minute:

  • Active items excludes deletion tombstones.
  • Active JSON value size sums the logical UTF-8 value bytes of active items.
  • Retained history BSON size measures retained documents, including metadata; it is not compressed disk size, index size or a billing estimate.
  • Retained versions can decrease when MongoDB removes expired history.

Snapshots are measurements, not a reconstruction from today's data. Hourly charts use the last available sample. The sampler scans current storage and retained history with a 10-second timeout per aggregation; very large installations may need incremental size counters. A timeout produces a gap, not a zero estimate.

GET /api/v1/admin/reports/changes accepts hours, optional end, and project. The endpoint is administrator-only like the other reports.

Saved views and CSV

On any report, enter a name and choose Save view. This saves the report type, relative time window and filters to this installation, shared with administrators. Click its name to reload the view or × to delete it. Saving a view does not freeze its results. The picker shows the 100 newest saved views.

Export CSV downloads current-period event buckets and available snapshots; usage exports also include live quota cards. Each row identifies its source and the report range and filters. Blank measurements stay blank. Text that could be interpreted as a spreadsheet formula is escaped. The export is generated locally from the report response; it never includes API-key secrets or stored JSON values.

Saved-view API: GET/POST /api/v1/admin/reports/saved and DELETE /api/v1/admin/reports/saved/:id. All require administrator authentication. POST accepts { name, kind, query }, with kind one of health, usage, changes; query contains string values for hours, project, apiKeyId and replica. Only applicable filters are used by each report.

Tenant scope

Tenant administrators see only their own traffic, quotas, pending publication snapshots, data growth and saved reports. Platform administrators see installation-wide totals. The server applies ownership from the stored credential, independently of report filters.

On this page