postgresql
postgresql
postgres
PostgreSQL and lock timeout issues – how to deal with them also in Ruby on Rails?
PostgreSQL lock timeouts strike during long migrations and complex transactions. How lock_timeout and statement_timeout actually work, quick fixes at the database role level, managing timeouts in Rails migrations, and global protection with StrongMigrations.
postgres
How can I check the size of the database and tables in PostgreSQL?
PostgreSQL database size checks in a few simple SQL queries: list all databases with pg_database and pg_size_pretty, then break down the biggest tables in a schema, indexes included. Spot what eats disk space before it slows backups and raises infrastructure costs.
Latest
How to track and log slow queries in Ruby on Rails applications?
Slow SQL queries in Rails can be caught in development, before they become production fires. Using ActiveSupport::Notifications and the sql.active_record event, you build a small performance guard that logs every query above a time threshold straight to your console.
How to effectively manage and terminate old PostgreSQL connections
Idle PostgreSQL connections eat memory and can hit the max_connections limit, blocking your app. How to find old sessions in pg_stat_activity, close them safely with pg_terminate_backend, and automate the cleanup so hanging connections never pile up again.