Hacker News new | past | comments | ask | show | jobs | submit login

To make it scale well, two things are required:

1. TRUNCATE if cleanup is needed (no DELETEs) + partitioning.

2. SELECT .. FOR UPDATE SKIP LOCKED or advisory locks.

It's worth learning from Skype's PgQ developed in 2000-s.

Update: found the work with advisory locks in the code, great.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: