metadatastore

package
v0.49.2 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Getter

type Getter interface {
	// Get finds and returns value of a given key.
	Get(key string) (string, bool)
}

type MetadataStore

type MetadataStore interface {
	Shared() Store
	Stage(stageID string) Store
}

func NewMetadataStore

func NewMetadataStore(apiClient apiClient, d *model.Deployment) MetadataStore

NewMetadataStore builds a metadata store for a given deployment. It keeps local data and makes sure that they are synced with the remote store.

type Putter

type Putter interface {
	// Put adds a single key, value into store.
	// If the key is already existing, it overwrite the old value by the new one.
	Put(ctx context.Context, key, value string) error
	// PutMulti adds multiple (key, value) into store.
	// If any key is already existing, it overwrite the old value by the new one.
	PutMulti(ctx context.Context, md map[string]string) error
}

type Store

type Store interface {
	Getter
	Putter
}

Jump to

Keyboard shortcuts

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