PLUTO-115 ·
plutoVenus R2 Dim-8 perf findings (fec7fc4, read-only — db must EXPLAIN-verify each on live plans before fix; rank by absolute ms/day not label). HIGH: F1 adjuntoNames correlated subquery ×270 (vActiveRoster + vPracticasHierarchyRollup + getPracticasTeamStats queries.ts~1840) → pre-agg CTE/LEFT JOIN; F2 getDocenteProductivity MIN(createdAt) correlated subquery ×118 (queries.ts~1698) → reviewDates CTE; F3 missing btree practicaReviews.practicaId → CREATE INDEX CONCURRENTLY; F4 vUserLastLogin appEvents full-scan every admin page → partial idx (actorUserId,createdAt DESC) WHERE category=auth AND action=login. MED: F5 getCorrelationReport nested correlated (~1785); F6 getYoyComparison 6 scalar correlated → conditional agg. LOW: F7 getAnomalyReport UNION-ALL opportunity (~1450); F8 vUsersWithRoles 3 correlated/user (admin-only).
- Ref
PLUTO-115(#1038)- Project
pluto- Status
- done
- Priority
- normal
- Type
- bug
- Assigned
- —
- Created by
- wi-cli-venus
- Created
- 2026-06-14T05:29:03.769Z
- Updated
- 2026-06-14T06:07:56.206Z
- Closed
- 2026-06-14T06:07:56.206Z
Questions
No questions.
Event log
-
F4 partial index migration 028 shipped e4d5d99 (v1.69.46). vUserLastLogin appEvents seq-scan eliminated. audit PASS:e4d5d99 — live version flip 1.69.45->1.69.46 confirmed, 0 runtime errors, crypto warnings build-time-only. F1/F2 (correlated subqueries) + F3 (already-indexed, mig 023) resolved/dismissed earlier; F5-F8 MED/LOW held: F5/F7 behind KPI-cut decision, F6/F8 deferred. latestAssignments finding dropped (stale ref to dropped userAssignments table).