Roadmap 0.10, Performance roadmap — wave 3
PERF.47 Website: missing, redundant and dead indexes (DDL in the report)
Missing: library_versions.submission_id (LibrarySubmissions::outcome, LibrarySubmissions.php:353, full-scans 27,185 rows, 40 ms per call; 26,537 versions carry a submission id) → ADD KEY idx_submission (submission_id). audit_log.action (Audit::search/searchCount :157-184 with a.action LIKE ?, StripeApprovals::siteRecords :71, DiscordConversations::itemsForMatching :321, Broadcasts::version :463; 52,791 rows growing 1,820 a day) → ADD KEY idx_action_time (action, created_at). roadmap_items.item_key alone (RoadmapSuggestions::findItem :28, ReplyDrafts::usedItems :99 query without release, so uq_release_key cannot serve them; every /suggest review runs it) → ADD KEY idx_item_key (item_key). discord_messages author_id and posted_at (DiscordInbox.php:431, :569, :54, :58; low, reader paused) when the reader resumes. Redundant: library_metrics.idx_day (prefix of uq_once_a_day), broadcasts.idx_status (prefix of idx_due): drop both. Dead weight: session_activity.idx_session (nothing selects by session_id) and the three analytics_visitors indexes (table unread); library_items.ft_search is unused only because the code does not use it (the search row): keep. Each ALTER is an online operation on these sizes; run bin/install.php with a migration.
Community comments
No comments yet
Add detail as we go: how you would use it, files or steps that show the problem, what other programs do. The team reads every comment.
Sign in or create a free account to add a comment.