tracker

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package tracker contains logic of service stats persistence. This is for the sake of making graphs for README.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Path   string            `json:"path"`
	Period duration.Duration `json:"period"`
}

Config is a configuration of a tracker.

func (*Config) Prepare

func (c *Config) Prepare() error

Prepare validates config.

type Tracker

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

Tracker is responsible for service stats persistence.

func NewTrackerFromConfig

func NewTrackerFromConfig(logger logr.Logger, cfg *Config, memLimiter memlimiter.Service) (*Tracker, error)

NewTrackerFromConfig is a constructor of a Tracker.

func (*Tracker) Quit

func (tr *Tracker) Quit()

Quit gracefully terminates tracker.

Jump to

Keyboard shortcuts

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