@bounda-dev/adapter-postgresql
v0.1.0
Published
PostgreSQL storage adapter for Bounda
Readme
@bounda-dev/adapter-postgresql
PostgreSQL storage for Bounda, for when one process is not enough.
npm install @bounda-dev/core @bounda-dev/adapter-postgresql// bounda.config.ts
import { postgresql } from "@bounda-dev/adapter-postgresql";
import { defineConfig } from "@bounda-dev/core/config";
export default defineConfig({
storage: postgresql({ url: process.env.DATABASE_URL }),
});Connection parts work too ({ host, database, user, port?, password?, ssl? }), and further
arguments set the schema, the table prefix and the pool size.
Appends take a transaction-scoped advisory lock, so global positions never have gaps for readers;
claims use FOR UPDATE SKIP LOCKED, so many web and worker processes can share one database
without stepping on each other.
Status
0.x. Until 1.0 the API can still change between minor versions, and every change that breaks something is called out in the changelog.
Docs: docs.bounda.dev/adapters/postgresql. Source and issues: github.com/bounda-dev/bounda.
