Documentation
¶
Overview ¶
Package db carries the schema migrations of the shared PostgreSQL database in the binary, so tests and tools apply the same files the migrator applies without reading them from a checkout.
Index ¶
Constants ¶
const RiverSchema = "river"
RiverSchema keeps River's job tables out of public. A goose migration creates it; River's migrator fills it.
const TrackingTable = "_migrations"
TrackingTable is goose's bookkeeping table for Migrations.
Variables ¶
This section is empty.
Functions ¶
func Migrate ¶
Migrate applies the goose and River migration streams under one lock: River does not share goose's.
func Migrations ¶
Migrations returns the goose migration files rooted like the directory the migrator reads, so a provider over either sees the same set.
func RiverMigrator ¶
func RiverMigrator[TTx any](driver riverdriver.Driver[TTx]) (*rivermigrate.Migrator[TTx], error)
RiverMigrator targets RiverSchema; the default resolves against search_path and silently lands in public. Use it for every migrate and validate call.
Types ¶
This section is empty.
Directories
¶
| Path | Synopsis |
|---|---|
|
pkg
|
|
|
outbox
Package outbox holds the River job arguments shared by the service that enqueues a job and the API, which works it, through the shared database.
|
Package outbox holds the River job arguments shared by the service that enqueues a job and the API, which works it, through the shared database. |
|
seed/postgres
command
|