Collector & Event Specifications

MetricLoom collectors operate as single-binary Linux daemons with strict memory caps and conditional HTTP caching.

Agent Runtime Profile

Compiled static Go daemon with zero runtime dependencies. Polls control configuration every 20s using weak ETag validation (304 Not Modified) and pushes aggregated counters every 60s.

sync_interval_sec: 20
stats_interval_sec: 60
transport: TLS 1.3 + Bearer SHA-256
fallback_cache: /var/lib/collector/cache.json

Telemetry Batch Schema

Events are serialized in compact UTF-8 JSON with monotonic timestamps and bounded concurrency windows for active endpoint counters.

{
  "node_slug": "eu-ams-edge-01",
  "recorded_at": "2026-12-04T06:00:00Z",
  "system": {
    "cpu_percent": 11.4,
    "ram_percent": 39.2,
    "rx_mbps": 42.8,
    "tx_mbps": 43.1
  },
  "counters": []
}
Component Protocol Retention / TTL Deduplication
Edge Collector JSON over TLS 1.3 Local ring buffer (5 min) ETag W/"sha256-16"
Webhook Relay POST + HMAC-SHA256 72h dead-letter queue Idempotency-Key header
Active State Table In-memory + UNLOGGED PG 120s sliding TTL Composite (node, tenant, addr)