3 ms·
Holding a transaction open for the duration of a request to an external service makes me nervous. I've seen similar code lock up the database and bring down pro
by maxbond 3y ago
Holding a transaction open for the duration of a request to an external service makes me nervous. I've seen similar code lock up the database and bring down production. Are you using timeouts and circuit breakers to control the length of the transactions?
- lomereiter 3y agoYes, you absolutely need to set a reasonable idle transaction timeout to avoid a disaster (bugs in the code happen) - this can also be done globally in the database settings.