logoalt Hacker News

MySQL foreign key cascade operations finally hit the binary log

30 pointsby marceloaltmannlast Monday at 8:01 PM13 commentsview on HN

Comments

TexanFellertoday at 12:38 AM

One of the main reasons I use Postgres is I've rarely(never?) seen an article like this posted about it. Every time I've touched MySQL I've found a new footgun.

show 1 reply
jbonatakistoday at 6:56 AM

This is excellent. In the past when replicating via Debezium from a system making heavy use of cascade deletes I’ve had to write a layer that infers these deletes by introspecting the database schema, building a graph of all cascades (sometimes several layers) and identifying rows that should have corresponding delete records. These can then be excluded in whatever downstream system via an anti-join. It works but it will be better to not have to do that and instead have first class support for cascades.

XCSmetoday at 12:16 AM

I always end up disabling bin log for single-db setups, and simlly run backup jobs. Using bin log drastically reduces performance. Am I crazy?

show 3 replies