GSM

GSM

@turnstep.bsky.social

Postgres. Lots of Postgres.

429 followers232 following176 posts

Interesting discussions about increasing the frequency of Postgres releases. Looks like we will end up somewhere more frequently than quarterly and less often than monthly. #postgres

So the problem is not "centralization creates a single point of failure." The problem is complete lack of reliable backups. Even a pg_dump backup (crappy, worst case kind of backup) should be shipped offsite, with multiple copies.

Disagree with this though: "You want checkpoints to be triggered by max_wal_size, not by checkpoint_timeout". That's reversed. You want smooth and regular checkpoints, time-driven, with wal size as the backstop.

Heh, almost every first attempt at solving Advent of Code puzzles with Postgres leads to "ERROR: integer out of range". Poor little int4, just not up to the job! #postgres #postgresql #adventofcode

Oh for Pete's sake, now there are some on the Postgres lists advocating *raising* random_page_cost default - by a lot! Crazy times. #postgres #postgresql

Working on some v19 features and managed to break my test Postgres instance worst than I ever have before. Every single SQL command causes the backend to crash. To be fair, I'm messing with the parser, but it's still a little jarring. :) #postgres #postgresql

Been working with a database that defaults to UPPERCASE for unquoted things, and wow, is that annoying after all these decades of calm, non-yelling lowercase Postgres code. :) #postgres #postgresql

Wondering if I should bother trying to raise the default track_activity_query_size in Postgres. It's been 1kb for a long time, and that seems too small for today's verbose apps, complex queries, and ORMs. #postgres

Inspired by a Slack discussion, here's how to tell how many of today's 86,400 seconds have been used up already: select round(extract(epoch from now() - 'today'::date)); #postgres

Use of domains came up on Postgres lists recently. I very seldom use them, always seems better to just use check constraints on a base type. Still more useful than enum however! #postgres #postgresql

Getting down to the finish line - hope my "initdb checkpoints on by default" patch and its cousin "don't dump stats to pg_dump by default" both survive as is! #postgres #postgresql

Postgres tip of the day: you can chain psql -c calls: psql -c 'alter system set random_page_cost = 1.5' -c 'select pg_reload_conf()' Bonus: they run in the same session, so you can even use vars. #postgres #postgresql

Postgres making some more progress towards not supporting 32-bit stuff. Or at least making our code less painful to work with it. Even Raspberry Pi can do 64-bit these days! #postgres

Pro tip: use long args when sending example commands to someone; less likely they will get it wrong. psql -X vs. psql --no-psqlrc As a bonus, it's usually a lot more self-documenting as well. #postgres

Interesting thread on -hackers about Postgres resizing shared_buffers on the fly (smaller to larger only!). Looks quite feasible, I think it will make it into v19 #postgres

Random idea: make psql smart enough to give feedback for long-running queries like CREATE INDEX as we have pg_stat_progress* #postgres #postgresql