pgstore: advisory lock hash collisions can serialize unrelated streams #160
Labels
No labels
bug
documentation
enhancement
investigation
nice-to-have
performance
production-ready
testing
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
ash/eskit#160
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Red team found:
hashtext(streamID)maps stream IDs to int32 advisory locks. Two different streams can hash to the same value, causing one to block while the other holds the lock. Under heavy load with many streams, this reduces throughput.Options
pg_advisory_xact_lock(bigint)with a 64-bit hashPriority
Medium — causes throughput degradation, not data corruption