4 ms·
If you want performance to completely tank, sure.
by xxpor 3y ago
If you want performance to completely tank, sure.
- hipadev23 3y agoAfaik, it only locks the row(s) in question. Do you have a setup where the same row is being updated by multiple clients all the time?
- jtc331 3y agoSELECT FOR UPDATE means two queries can’t _read_ the same row at the same time, right?
- quickthrower2 3y agoSQL Server will escalate locks. Because keeping a million rows locked is expensive.
- dig1 3y agoThis can easily happen if you have multiple services that can write/update in the same table/rows and rely on database coordination instead of using an external queue like Kafka. Postgres (presumably other databases) can propagate these locks to table locks [1] and cause contention for the whole infra. [1] https://blog.heroku.com/curious-case-table-locking-update-query https://blog.heroku.com/curious-case-table-locking-update-qu...