import { i as Querier, n as Dialect } from "./index-DrgOX0Fu.js";
//#region src/locking.d.ts
/**
 * Execute fn under an advisory lock.
 * - Postgres: acquires pg_advisory_xact_lock(key) within the transaction
 * - SQLite: passthrough (single-writer serializes at write-lock grain)
 *
 * BEHAVIORAL NOTE: PG blocks concurrent callers per-key; SQLite serializes
 * at coarser grain (the write lock). Callers needing fine-grained fairness
 * must know SQLite has different timing characteristics.
 */
declare function withAdvisoryLock<T>(db: Querier<any>, key: bigint, fn: () => Promise<T>, dialect: Dialect): Promise<T>;
//#endregion
export { withAdvisoryLock };