postgres

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PostgresStore

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

PostgresStore implements the Store interface using PostgreSQL as the backend

func NewStore

func NewStore(config *config.PostgresConfig) (*PostgresStore, error)

NewPostgresStore creates a new PostgreSQL store with the given configuration

func (*PostgresStore) Close

func (p *PostgresStore) Close() error

Close cleanly shuts down the store

func (*PostgresStore) Delete

func (p *PostgresStore) Delete(ctx context.Context, key string) error

Delete removes a feature flag

func (*PostgresStore) Get

func (p *PostgresStore) Get(ctx context.Context, key string) (*core.FeatureFlag, error)

Get retrieves a feature flag by key

func (*PostgresStore) GetAll

func (p *PostgresStore) GetAll(ctx context.Context) ([]core.FeatureFlag, error)

GetAll retrieves all feature flags

func (*PostgresStore) HealthCheck

func (p *PostgresStore) HealthCheck(ctx context.Context) error

HealthCheck verifies store connectivity

func (*PostgresStore) Set

func (p *PostgresStore) Set(ctx context.Context, flag core.FeatureFlag) error

Set creates or updates a feature flag

Jump to

Keyboard shortcuts

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