<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>migrations on Ikoma's Blog</title><link>https://blog.yusukeikoma.com/tags/migrations/</link><description>Recent content in migrations on Ikoma's Blog</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Fri, 30 Oct 2026 17:00:00 +0900</lastBuildDate><atom:link href="https://blog.yusukeikoma.com/tags/migrations/index.xml" rel="self" type="application/rss+xml"/><item><title>Avoiding a PostgreSQL DROP TABLE deadlock by taking LOCK TABLE NOWAIT in a Flyway beforeEachMigrate callback</title><link>https://blog.yusukeikoma.com/posts/flyway-drop-table-deadlock-lock-nowait/</link><pubDate>Fri, 30 Oct 2026 17:00:00 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/flyway-drop-table-deadlock-lock-nowait/</guid><description>A migration that only dropped an old table deadlocked in production twice and rolled back. DROP TABLE also takes the strongest lock on the tables its foreign keys reference, and a running worker read those tables in the opposite order. After comparing lock_timeout and plain reruns, I left the applied migration untouched and took all the needed locks up front with NOWAIT in a Flyway beforeEachMigrate callback.</description></item></channel></rss>