metastore

package
v3.3.1 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2024 License: AGPL-3.0 Imports: 33 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DataDir string     `yaml:"data_dir"`
	Raft    RaftConfig `yaml:"raft"`
}

func (*Config) RegisterFlags

func (cfg *Config) RegisterFlags(f *flag.FlagSet)

type FSM

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

func (*FSM) Apply

func (fsm *FSM) Apply(l *raft.Log) interface{}

func (*FSM) Restore

func (fsm *FSM) Restore(snapshot io.ReadCloser) error

func (*FSM) Snapshot

func (fsm *FSM) Snapshot() (raft.FSMSnapshot, error)

type Metastore

type Metastore struct {
	services.Service
	metastorepb.MetastoreServiceServer
	// contains filtered or unexported fields
}

func New

func New(config Config, logger log.Logger, reg prometheus.Registerer, hs health.Service) (*Metastore, error)

func (*Metastore) AddBlock

func (*Metastore) ListBlocksForQuery

func (*Metastore) Shutdown

func (m *Metastore) Shutdown() error

type RaftConfig

type RaftConfig struct {
	Dir string `yaml:"dir"`

	BootstrapPeers   []string `yaml:"bootstrap_peers"`
	ServerID         string   `yaml:"server_id"`
	BindAddress      string   `yaml:"bind_address"`
	AdvertiseAddress string   `yaml:"advertise_address"`

	ApplyTimeout time.Duration `yaml:"apply_timeout" doc:"hidden"`
}

func (*RaftConfig) RegisterFlags

func (cfg *RaftConfig) RegisterFlags(f *flag.FlagSet)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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