Module
postgres
github.com/riducms/ridu/adapters/postgres — The official PostgreSQL store, safe development schema sync, and immutable production migration runner.
Functions 3
postgres.Open()Open the PostgreSQL store with bounded default pool settings.
postgres.OpenWithConfig()Open the store with explicit pool and PostgreSQL session bounds.
postgres.ProjectMigrations()ProjectMigrations binds checksum-protected callbacks into the compiled project while PostgreSQL retains ownership of every migration transaction and the credential-bearing connection boundary.
Types 4
type postgres.PoolConfigProduction connection-pool, upload-lock-pool, lifetime, health, and server timeout controls.
type postgres.StoreA PostgreSQL implementation of Ridu’s document, snapshot, auth, preference, task, job, lock, upload-reference, and migration store contracts.
type postgres.StatementOne ordered development schema change.
type postgres.FieldRenameOne migration-time field identity match confirmed by the application author.
Methods 54
Store.Close()Store.Ping()Store.Ready()Store.ReadyWithMigrationHistory()Store.Begin()Store.BeginSnapshot()Store.Plan()Store.ApplyPlan()MaintenanceRequiredError.Error()MaintenanceRequiredError.Is()SafetyError.Error()Store.AcquireDocumentLock()Store.AllowAuthAttempt()Store.CancelTask()Store.ChangePasswordHash()Store.ClaimTasks()Store.CompleteTask()Store.CreateAPIKey()Store.CreateAuthToken()Store.CreateSession()Store.DeleteAPIKey()Store.DeletePreference()Store.DeletePreferences()Store.DeleteSession()Store.DeleteUserSession()Store.DeleteUserSessions()Store.DismissTaskForTarget()Store.EnqueueTask()Store.FailTask()Store.FindAPIKey()Store.FindAuthCredential()Store.FindDocumentLock()Store.FindSession()Store.FindTask()Store.ForceUnlock()Store.GetPreference()Store.HeartbeatTask()Store.ListAPIKeys()Store.ListSessions()Store.ListTasks()Store.LockUploadObjects()Store.PruneExpiredAuth()Store.PruneTasks()Store.RecordFailedLogin()Store.ReleaseDocumentLock()Store.ReleaseTask()Store.ResetLoginAttempts()Store.ResetPasswordWithToken()Store.RotateSession()Store.SetPasswordHash()Store.SetPreference()Store.TouchAPIKey()Store.UpgradePasswordHash()Store.VerifyEmailWithToken()
Production migrations 19
postgres.BuildArtifact()Use embedded Atlas planning plus confirmed semantic rename intent to build an immutable migration artifact.
postgres.BuildArtifactWithPreviousPlanner()Plan a reviewed migration against the exact physical planner contract recorded by its predecessor.
type postgres.RenameConfirmed collection or field identity continuity used during migration planning.
type postgres.MigrationStepStatusDurable status and checkpoint for one production migration step.
type postgres.RenameKindThe migration address being renamed.
type postgres.SafetyErrorA valid transition that needs destructive approval or cannot be determined safe.
postgres.VerifyArtifacts()Replay complete history in an isolated temporary schema, then always drop it.
postgres.VerifyArtifactsWithOptions()Verify history using the same operational admissions and timeouts as application.
Store.ApplyArtifacts()Store.ApplyArtifactsWithOptions()Store.ArtifactStatus()Store.ArtifactPlan()type postgres.RunnerOptionsExplicit operational admissions, bounded timeouts, and resumable boundaries.
type postgres.MigrationStatusOne artifact’s ledger state and optional phased progress.
type postgres.MigrationPhaseStatusOne immutable phase and its step checkpoints.
type postgres.MaintenanceRequiredErrorLists artifacts refused before mutation because maintenance admission is required.
type postgres.MigrationNoticeMachine-readable non-blocking runner context.
constant postgres.AtlasVersionThe embedded Atlas planner version persisted into migration artifacts.
type postgres.Migration boundary codesStable operator-facing code and sentinel error for migration admission and reproducibility failures.
Constants 4
constant postgres.CodeMigrationPlanMismatchCodeMigrationPlanMismatch is the stable boundary code for an artifact whose contract cannot be reproduced from its embedded immutable inputs.
constant postgres.NoticeAtlasProvenanceNoticeAtlasProvenance identifies replay by an Atlas runner version other than the one that planned the frozen artifact SQL.
constant postgres.RenameCollectionRenameCollection preserves a collection while changing its derived identity.
constant postgres.RenameFieldRenameField preserves a field while changing its derived identity.
Variables 1
variable postgres.ErrMaintenanceRequiredErrMaintenanceRequired identifies pending whole-dataset work that requires an explicit maintenance window admission.