history

package
v0.21.5 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2022 License: MPL-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const SchemaName = "history"

Variables

This section is empty.

Functions

func TransformDSN added in v0.20.0

func TransformDSN(inputDSN string) (string, error)

TransformDSN sets the search_path of the given DSN to the history schema

Types

type Config

type Config struct {
	// Retention of data in days, defaults to 7
	Retention int `default:"7" hcl:"retention,optional"`
	// TimeInterval defines how chunks are split by time defaults to one chunk per 24 hours.
	TimeInterval int `default:"24" hcl:"interval,optional"`
	// TimeTruncation truncates fetch time by hour, for example if we fetch with TimeTruncation = 1 at 11:25 the fetch date will truncate to 11:00
	// defaults to 24 hours, which means one set of fetch data per day.
	TimeTruncation int `default:"24" hcl:"truncation,optional"`
}

func (Config) FetchDate

func (c Config) FetchDate() time.Time

Jump to

Keyboard shortcuts

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