refactor(databases): remove DocumentsDB collection usage page#3111
Conversation
The per-service DocumentsDB usage endpoints were removed in cloud (appwrite-labs/cloud#4679, 'remove per-service /usage endpoints') as they duplicated the org/project usage surface. The console collection usage page was the only consumer of documentsDB.getCollectionUsage, so remove it and its command-center 'Go to usage' entry. Database/table/project usage pages are unaffected (they use the retained tablesDB.* usage endpoints).
Greptile SummaryThis PR removes the DocumentsDB collection usage page and its command-center shortcut following the removal of the
Confidence Score: 3/5The route deletion is incomplete — the Usage tab in the collection header still navigates to the deleted page, leaving a broken tab visible to all multi-db users. The keyboard shortcut and route files are cleaned up correctly, but header.svelte was not updated. Every collection header rendered for multi-db users will show a Usage tab that resolves to a missing route. The fix is a small, isolated deletion in header.svelte. src/routes/(console)/project-[region]-[project]/databases/database-[database]/collection-[collection]/header.svelte — the Usage tab entry needs to be removed. Important Files Changed
Reviews (1): Last reviewed commit: "refactor(databases): remove DocumentsDB ..." | Re-trigger Greptile |
What
Removes the DocumentsDB collection usage page and its command-center
Go to usageentry.Why
The per-service DocumentsDB (and VectorsDB)
/usageendpoints were removed in cloud — appwrite-labs/cloud#4679 ("chore(databases): remove per-service /usage endpoints", merged 2026-07-08) — because they duplicated the org/project usage surface. The console's collection usage page was the only consumer of the now-deleteddocumentsDB.getCollectionUsage, so calling it against any post-#4679 server 404s / breaks the type-check once the SDK is bumped.Scope
database-[database]/collection-[collection]/usage/[[period]]/(+page.svelte,+page.ts)Go to usagecommand from the collection+layout.svelteUnaffected (retained endpoints): the database, table, and project usage pages all use
tablesDB.*(listUsage,getUsage,getTableUsage). The sharedUsageview component stays (still used by the table usage page). Note: DocumentsDB is gated behind themulti-dbfeature flag, so this page was only reachable for opted-in accounts.Verification
bun run check→ 0 errors (88 pre-existing warnings unchanged). Prettier clean; ESLint 0 errors.