mirror of
https://github.com/RuoJi6/ARTEX.git
synced 2026-11-27 02:21:50 +08:00
- Add partial covering index on intercept_pending(task_id, created_at DESC) INCLUDE (agent_name) WHERE status = 'pending'.
- Add GET /api/intercept/pending/summary (global count or per-task count + agent_names) and ?task_id= filtering on GET /api/intercept/pending.
- Cap unpaginated GET /api/intercept/task/{taskID} at 200 rows and remove unused tasks JOIN from non-search approval queries.
- Replace unbounded SELECT COUNT(*) in paginated approval queries with end-of-list shortcut, pg_class/pg_stat catalog estimate for large unfiltered tables, and bounded counting (10,000 cap) for large filtered sets.
- Deduplicate task detail and sessions-tab polling via single pending summary poll, switch sidebar badge to summary count, and guard approval polling against background tabs, overlapping requests, and deep-page/search churn.
Fixes #186