ctdean / backtick

A background job processor using Clojure and Postgres
27 stars 3 forks source link

Use PG skip locked when reading from the queue #34

Closed ctdean closed 4 years ago

ctdean commented 4 years ago

See skip locked at https://www.postgresql.org/docs/9.5/sql-select.html#SQL-FOR-UPDATE-SHARE

This should improve the queue popping performance.

carriegriffin commented 4 years ago

+1 seems like skip lock should work in this case.