Skip to content

advisoryLock

Advisory-lock helpers for any pg.Pool-compatible pool.

PostgreSQL advisory locks belong to a connection, not a pool. These helpers reserve one pooled client for the full callback, acquire the lock on that client, and release both in the correct order.