Apple
a4e95482bc
feat(matrix-bridge-dagi): add rate limiting (H1) and metrics (H3)
H1 — InMemoryRateLimiter (sliding window, no Redis):
- Per-room: RATE_LIMIT_ROOM_RPM (default 20/min)
- Per-sender: RATE_LIMIT_SENDER_RPM (default 10/min)
- Room checked before sender — sender quota not charged on room block
- Blocked messages: audit matrix.rate_limited + on_rate_limited callback
- reset() for ops/test, stats() exposed in /health
H3 — Extended Prometheus metrics:
- matrix_bridge_rate_limited_total{room_id,agent_id,limit_type}
- matrix_bridge_send_duration_seconds histogram (invoke was already there)
- matrix_bridge_invoke_duration_seconds buckets tuned for LLM latency
- matrix_bridge_rate_limiter_active_rooms/senders gauges
- on_invoke_latency + on_send_latency callbacks wired in ingress loop
16 new tests: rate limiter unit (13) + ingress integration (3)
Total: 65 passed
Made-with: Cursor
2026-03-05 00:54:14 -08:00
..
2026-02-20 17:57:40 +01:00
2026-02-09 08:46:46 -08:00
2026-03-03 07:14:14 -08:00
2026-02-21 17:02:55 +01:00
2026-03-03 07:14:14 -08:00
2026-03-03 07:14:14 -08:00
2026-01-28 06:40:34 -08:00
2026-01-28 06:40:34 -08:00
2026-03-03 07:14:14 -08:00
2026-01-17 08:16:37 -08:00
2026-01-17 08:16:37 -08:00
2026-02-19 00:14:12 -08:00
2026-02-19 00:14:12 -08:00
2026-02-19 00:14:18 -08:00
2026-02-09 08:46:46 -08:00
2026-02-09 08:46:46 -08:00
2026-02-27 03:09:12 -08:00
2026-02-09 08:46:46 -08:00
2026-01-17 08:16:37 -08:00
2026-02-09 08:46:46 -08:00
2026-01-28 06:40:34 -08:00
2026-02-09 08:46:46 -08:00
2026-02-09 08:46:46 -08:00
2026-02-09 11:46:15 -08:00
2026-03-05 00:54:14 -08:00
2026-03-03 07:14:14 -08:00
2026-03-03 07:14:14 -08:00
2026-03-03 07:14:14 -08:00
2026-03-03 07:15:39 -08:00
2026-03-03 07:14:14 -08:00
2026-02-19 00:14:12 -08:00
2026-02-19 00:14:12 -08:00
2026-02-19 00:14:12 -08:00
2026-02-19 00:14:12 -08:00
2026-02-09 08:46:46 -08:00
2026-02-20 17:57:40 +01:00
2026-01-28 06:40:34 -08:00
2026-01-28 06:40:34 -08:00
2026-02-09 08:46:46 -08:00
2026-01-28 06:40:34 -08:00
2026-03-03 07:14:14 -08:00
2026-02-09 08:46:46 -08:00
2026-02-19 00:14:18 -08:00
2026-03-03 08:03:49 -08:00
2026-03-03 07:14:14 -08:00
2026-03-03 07:13:29 -08:00
2025-11-17 05:24:36 -08:00