Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var MigrationsFS embed.FS
MigrationsFS contains SQL migrations for both PostgreSQL and SQLite.
The migrations are organized in a dialect-aware structure:
- Root files (data/sql/migrations/*.sql) contain PostgreSQL migrations
- SQLite overrides are in data/sql/migrations/sqlite/*.sql
The go-persistence-bun loader will automatically select the correct migrations based on the database dialect being used.
Usage:
import "io/fs"
import users "github.com/goliatone/go-users"
import persistence "github.com/goliatone/go-persistence-bun"
migrationsFS, _ := fs.Sub(users.MigrationsFS, "data/sql/migrations")
client.RegisterDialectMigrations(
migrationsFS,
persistence.WithDialectSourceLabel("."),
persistence.WithValidationTargets("postgres", "sqlite"),
)
Functions ¶
func GetMigrationsFS ¶
GetMigrationsFS exposes the SQL migration files so host applications can register them with go-persistence-bun (or another migration runner).
Types ¶
type Commands ¶
Re-export the service package entry point so consumers can do `users.New(...)` without importing internal wiring helpers.
type Config ¶
Re-export the service package entry point so consumers can do `users.New(...)` without importing internal wiring helpers.
type PreferenceResolver ¶
type PreferenceResolver = service.PreferenceResolver
Re-export the service package entry point so consumers can do `users.New(...)` without importing internal wiring helpers.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package activity provides default persistence helpers for the go-users ActivitySink.
|
Package activity provides default persistence helpers for the go-users ActivitySink. |
|
adapter
|
|
|
goauth
Package goauth provides adapters that wrap github.com/goliatone/go-auth repositories so they satisfy go-users interfaces without extra plumbing.
|
Package goauth provides adapters that wrap github.com/goliatone/go-auth repositories so they satisfy go-users interfaces without extra plumbing. |
|
Package command exposes go-command compatible command handlers implementing go-users business logic (lifecycle transitions, invites, role updates, etc.).
|
Package command exposes go-command compatible command handlers implementing go-users business logic (lifecycle transitions, invites, role updates, etc.). |
|
examples
|
|
|
admin
command
|
|
|
commands
command
|
|
|
pkg
|
|
|
Package preferences stores scoped user preference records and exposes helpers to resolve effective settings using go-options.
|
Package preferences stores scoped user preference records and exposes helpers to resolve effective settings using go-options. |
|
Package profile exposes storage adapters for the user_profiles table.
|
Package profile exposes storage adapters for the user_profiles table. |
|
Package query hosts read-side projections and DTO-friendly query helpers consumed by go-admin/go-cms dashboards.
|
Package query hosts read-side projections and DTO-friendly query helpers consumed by go-admin/go-cms dashboards. |
|
Package registry contains interfaces and default implementations for the custom role registry.
|
Package registry contains interfaces and default implementations for the custom role registry. |