rollup

package
v0.8.6 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2019 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Error = errs.Class("rollup error")
)

Error is a standard error class for this package.

Functions

This section is empty.

Types

type Config

type Config struct {
	Interval      time.Duration `help:"how frequently rollup should run" devDefault:"120s" default:"6h"`
	MaxAlphaUsage memory.Size   `help:"the bandwidth and storage usage limit for the alpha release" default:"25GB"`
}

Config contains configurable values for rollup

type Rollup

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

Rollup is the service for totalling data on storage nodes on daily intervals

func New

func New(logger *zap.Logger, db accounting.DB, interval time.Duration) *Rollup

New creates a new rollup service

func (*Rollup) RollupRaws

func (r *Rollup) RollupRaws(ctx context.Context) error

RollupRaws rolls up raw tally

func (*Rollup) Run

func (r *Rollup) Run(ctx context.Context) (err error)

Run the Rollup loop

Jump to

Keyboard shortcuts

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