4 ms·
I’d like to see you debug a database migration with a runtime debugger. The issue starts after about two million entries and only affects a subset of them. Have
by eurasiantiger 4y ago
I’d like to see you debug a database migration with a runtime debugger. The issue starts after about two million entries and only affects a subset of them. Have fun!
- hamburglar 4y agoIs it reproduceable? If so, easy: set a conditional breakpoint on the ones where the problem is known to occur. Step through them. A database migration is a pretty serialized operation. It’s perfect. Having lots of data or lots of iterations is really no burden unless you think debugging means manually stepping through everything.
- eurasiantiger 4y agoLet’s say it’s spurious and seemingly resource-dependent; data shape issues etc. would be apparent from the result data and maybe not need that much debugging. Speaking from experience, a migration is also a pretty buffered operation (especially over a network), and stopping the migration at a breakpoint before the failure occurs will almost certainly give all layers enough time to flush this and that so that the problem magically disappears.