Skip to content

Comment on Pgmigrate – Pgcopydb Rewritten in Go

Comments

After fighting crash after crash with pgcopydb v17 and v18 I decided to bite the bullet and write my own in Golang.

I picked Golang because most issues with pgcopydb were related to concurrency bugs and memory leaks. There is nothing in this tool that requires C, Golang is totally fine and comes with a good concurrency built-in and a garbage collector.

A few more notable improvements:

- I use binary format instead wal2json - Optional control plane with web interface - CDC replay runs concurrently (partition by fk)

I had a very similar story back pre-Go-v1, was frustrated trying to debug a C memory leak in concurrent code. Switched to Go in a few weeks, less code, no bugs in this realm, more features. I was hooked and have been a proud gopher since

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.