inmem

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: May 22, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Archive

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

Archive implements an in-mmeory archive backend, that provides no useful utility beyond testing archive behavior. DO NOT USE in production.

func New

func New(ctx context.Context, cfg Config, s *settings.Settings) (*Archive, error)

func (*Archive) Close

func (a *Archive) Close(context.Context) error

func (*Archive) History

func (a *Archive) History(context.Context, []byte) ([][]byte, error)

func (*Archive) Put

func (a *Archive) Put(ctx context.Context, versions ...[]byte) error

type Config

type Config struct {
	History []string `json:"history"`
}

Config defines backend specific configuration

Jump to

Keyboard shortcuts

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