runtime

package
v0.4.10 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: AGPL-3.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitializeEmpty added in v0.4.2

func InitializeEmpty(fileName string) error

func InitializeNew

func InitializeNew(fileName, dir string) (err error)

Types

type DBStats added in v0.3.7

type DBStats struct {
	FreePageN     int `json:"free_pages" yaml:"free_pages"`
	PendingPageN  int `json:"pending_pages" yaml:"pending_pages"`
	FreeAlloc     int `json:"free_pages_bytes" yaml:"free_pages_bytes"`
	FreelistInuse int `json:"free_list_bytes" yaml:"free_list_bytes"`

	TxN     int `json:"started_read_transactions" yaml:"started_read_transactions"`
	OpenTxN int `json:"open_read_transactions" yaml:"open_read_transactions"`

	TxStats TxStats // global, ongoing stats.
}

type Runtime

type Runtime interface {
	http.Handler
	Shutdown() error
	Update(func(tx bolted.SugaredWriteTx) error) error
	Read(func(tx bolted.SugaredReadTx) error) error
	GetDBStats() (*DBStats, error)
}

func Open

func Open(fileName string, logger logr.Logger) (Runtime, error)

type TxStats added in v0.3.7

type TxStats struct {
	PageCount int `json:"page_allocations" yaml:"page_allocations"`
	PageAlloc int `json:"page_allocations_bytes" yaml:"page_allocations_bytes"`

	// Cursor statistics.
	CursorCount int `json:"cursor_count" yaml:"cursor_count"`

	// Node statistics
	NodeCount int `json:"node_count" yaml:"node_count"`
	NodeDeref int `json:"node_dereferences" yaml:"node_dereferences"`

	// Rebalance statistics.
	Rebalance     int           `json:"node_rebalances" yaml:"node_rebalances"`
	RebalanceTime time.Duration `json:"node_rebalancing_time" yaml:"node_rebalancing_time"`

	// Split/Spill statistics.
	Split     int           `json:"node_splits" yaml:"node_splits"`
	Spill     int           `json:"node_spills" yaml:"node_spills"`
	SpillTime time.Duration `json:"node_spilling_time" yaml:"node_spilling_time"`

	// Write statistics.
	Write     int           `json:"writes" yaml:"writes"`
	WriteTime time.Duration `json:"writing_time" yaml:"writing_time"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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