Page MenuHomePhabricator

[keyserver] Revert D4675 window function for getMessageInfos
ClosedPublic

Authored by ashoat on Aug 10 2022, 12:29 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 22, 9:17 AM
Unknown Object (File)
Mon, Nov 18, 3:15 PM
Unknown Object (File)
Sun, Nov 10, 6:54 PM
Unknown Object (File)
Sun, Nov 10, 6:19 PM
Unknown Object (File)
Sat, Nov 2, 6:32 PM
Unknown Object (File)
Sat, Nov 2, 6:32 PM
Unknown Object (File)
Sat, Nov 2, 6:31 PM
Unknown Object (File)
Sat, Nov 2, 6:20 PM

Details

Summary

See context on Linear. The new query behaves differently from the old query for messages that have multiple associated uploads. We want to return 20 distinct messages, not 20 rows.

There might be a way to keep the window function construction, but I don't have time right now to investigate. The old query is definitely messier than the new one, but the performance is approximately the same after D4674 and D4673.

Test Plan

I ran the old query on MariaDB in production and confirmed it works, returns the right number of rows, and has approximately the same performance as the new query

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable