MetricsInflux

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2025 License: MIT Imports: 10 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewInflux

func NewInflux(serviceName shared.ServiceName, config *InfluxConfig) (metrics.MetricsInterface, error)

Types

type Influx

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

func (*Influx) Connect

func (i *Influx) Connect() error

func (*Influx) LogPoint

func (i *Influx) LogPoint(point metrics.MetricPoint, values metrics.MetricValues)

type InfluxConfig

type InfluxConfig struct {
	Host string `config:"INFLUXDB_HOST" default:"localhost"`
	Port int    `config:"INFLUXDB_PORT" default:"8086"`

	Token        shared.Secret `config:"INFLUXDB_TOKEN"`
	Organization string        `config:"INFLUXDB_ORG"`
	Bucket       string        `config:"INFLUXDB_BUCKET"`
}

func (*InfluxConfig) GetAddress

func (c *InfluxConfig) GetAddress() string

Jump to

Keyboard shortcuts

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