Help us shape the future of Go! Take the 2026 Go Developer Survey

pgprofile

package
v0.4.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package pgprofile is the shared availability and curated SQL authority for PostgreSQL profiles. Descriptors own their data; callers receive fresh copies.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateExtensionSQL

func CreateExtensionSQL(name, fixedSchema string) string

CreateExtensionSQL keeps installation independent of the management search_path. fixedSchema is the control-file schema, or empty when the extension has none. Fixed-schema extensions select their own namespace; all others belong in public.

func IDs

func IDs() []string

func SelectedExtensionPreloads

func SelectedExtensionPreloads(selected []string, bundle nativeartifacts.Artifact) []string

Types

type Descriptor

type Descriptor struct {
	// contains filtered or unexported fields
}

func Get

func Get(id string) (Descriptor, error)

func Resolve

func Resolve(selected []string, major int) ([]Descriptor, error)

Resolve returns profiles in declaration order, irrespective of user ordering or duplicates.

func (Descriptor) Artifacts

func (d Descriptor) Artifacts(major int) []string

func (Descriptor) BasePreloads

func (d Descriptor) BasePreloads() []string

func (Descriptor) ExtensionNames

func (d Descriptor) ExtensionNames(major int) []string

func (Descriptor) Extensions

func (d Descriptor) Extensions(major int) []Extension

func (Descriptor) ID

func (d Descriptor) ID() string

func (Descriptor) Majors

func (d Descriptor) Majors() []int

func (Descriptor) Packages

func (d Descriptor) Packages(major int) []string

Pins are from the Percona ppg-{16,17,18} noble binary-amd64 indexes. Supabase retains its historical PG17 package slice, including its order.

func (Descriptor) Parameters

func (d Descriptor) Parameters() map[string]string

func (Descriptor) Plan

func (d Descriptor) Plan(components, selected []string, major int) []initsql.Step

Plan is curated, not caller SQL. Supabase retains its existing immutable plan.

func (Descriptor) Preloads

func (d Descriptor) Preloads(selected []string) []string

func (Descriptor) PrepareCommands

func (d Descriptor) PrepareCommands(layout infra.Layout, major int) ([]string, error)

func (Descriptor) ReservedRole

func (d Descriptor) ReservedRole(name string) bool

func (Descriptor) ReservedSchemas

func (d Descriptor) ReservedSchemas() []string

func (Descriptor) Supports

func (d Descriptor) Supports(major int) bool

func (Descriptor) UpgradeRules

func (d Descriptor) UpgradeRules() UpgradeRules

func (Descriptor) Validate

func (d Descriptor) Validate(major int) error

type Extension

type Extension struct {
	Name    string `json:"name"`
	Source  string `json:"source"`
	Preload bool   `json:"preload"`
	Order   int    `json:"order"`
}

type UpgradeRules

type UpgradeRules struct {
	InstallBothMajors bool
	UpdateExtensions  bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL