store

package
v3.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrRetrieveFailed       = errors.New("failed to retrieve config item")
	ErrClientInitialization = errors.New("failed to initialize the client")
	ErrEmptyResponse        = errors.New("value retrieved but empty for token")
	ErrServiceCallFailed    = errors.New("failed to complete the service call")
	ErrPluginNotFound       = errors.New("plugin does not exist")
)
View Source
var ErrTokenRetrieval = errors.New("failed to exchange token for value")

Functions

This section is empty.

Types

type Plugin

type Plugin struct {
	Implementations config.ImplementationPrefix
	SourcePath      string
	Version         string
	ClientCleanUp   func()
	// contains filtered or unexported fields
}

Plugin is responsible for managing the plugin lifecycle within the configmanager flow. Each Implementation will initialise exactly one instance of the plugin

func NewPlugin

func NewPlugin(ctx context.Context, path string) (*Plugin, error)

NewPlugin Plugin gets called once per implementation

func (*Plugin) GetValue

func (p *Plugin) GetValue(token *config.ParsedTokenConfig) (string, error)

func (*Plugin) WithTokenStore

func (p *Plugin) WithTokenStore(ts tokenstore.TokenStore)

type Store

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

func New

func New(ctx context.Context) *Store

func (*Store) GetValue

func (s *Store) GetValue(implemenation *config.ParsedTokenConfig) (string, error)

func (*Store) Init

func (s *Store) Init(ctx context.Context, implt []string) error

Init ensures all the discovered tokens have their implementations initialised

func (*Store) PluginCleanUp

func (s *Store) PluginCleanUp()

PluginCleanUp ensures the plugins are properly shut down

Jump to

Keyboard shortcuts

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