"Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearLE

Day 41 - pg_stat_statements, the critical nature data plays with ORM code (Diesel) in lemmy_server

When using an ORM like Diesel, it may make the Rust code look smaller and easy to follow, but it puts more burden on you using a tool like pg_stat_statements in production on real data to ensure sanity checks are done that a single query isn't fetching 50,000 rows of data when run in production vs. a nearly empty testing system. It is critical that actual real-world patterns of data be checked for how frequently the code is running repeat queries and the number of rows being returned being sensible. pg_stat_statements is is one of those sanity checks.

It was spelled out here: https://lemmy.ml/post/1361757 - and that getting data out of the big servers was really important: https://lemm.ee/comment/350801

1
0
Comments 0