Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Enable bool `yaml:"enable"` Address string `yaml:"address"` Port int `yaml:"port"` UDPAddress string `yaml:"udp_address"` Database string `yaml:"database"` // precision: n, u, ms, s, m or h Precision string `yaml:"precision"` UserName string `yaml:"username"` Password string `yaml:"password"` MaxIdleConns int `yaml:"max-idle-conns"` MaxIdleConnsPerHost int `yaml:"max-idle-conns-per-host"` IdleConnTimeout int `yaml:"idle-conn-timeout"` }
type CustomConfig ¶
type CustomConfig struct { Enabled bool `yaml:"enabled"` Address string `yaml:"address"` Port int `yaml:"port"` UDPAddress string `yaml:"udp_address"` Database string `yaml:"database"` // precision: n, u, ms, s, m or h Precision string `yaml:"precision"` UserName string `yaml:"username"` Password string `yaml:"password"` ReadUserName string `yaml:"read-username"` ReadPassword string `yaml:"read-password"` MaxIdleConns int `yaml:"max-idle-conns"` MaxIdleConnsPerHost int `yaml:"max-idle-conns-per-host"` IdleConnTimeout int `yaml:"idle-conn-timeout"` FlushSize int `yaml:"flush-size"` FlushTime int `yaml:"flush-time"` }
CustomConfig Custom Configuration
type HTTPClient ¶
type HTTPClient struct { Client client.Client BatchPointsConfig client.BatchPointsConfig }
HTTPClient HTTP Client
func (*HTTPClient) FluxDBHttpClose ¶
func (p *HTTPClient) FluxDBHttpClose() (err error)
FluxDBHttpClose ...
func (*HTTPClient) FluxDBHttpWrite ¶
func (p *HTTPClient) FluxDBHttpWrite(bp client.BatchPoints) (err error)
FluxDBHttpWrite ...
type Metrics ¶
type Metrics struct { InfluxDBHttpClient *HTTPClient // contains filtered or unexported fields }
Metrics ...
func NewMetrics ¶
func NewMetrics(influxDBHttpClient *HTTPClient, conf *CustomConfig) (*Metrics, error)
NewMetrics ...
func (*Metrics) AddPoint ¶
func (mt *Metrics) AddPoint(metricsData *MetricsData) error
Directories
¶
Path | Synopsis |
---|---|
Package client implements a now-deprecated client for InfluxDB; use github.com/ztalab/zta-tools/influxdb/client/v2 instead.
|
Package client implements a now-deprecated client for InfluxDB; use github.com/ztalab/zta-tools/influxdb/client/v2 instead. |
models
Package models implements basic objects used throughout the TICK stack.
|
Package models implements basic objects used throughout the TICK stack. |
pkg/escape
Package escape contains utilities for escaping parts of InfluxQL and InfluxDB line protocol.
|
Package escape contains utilities for escaping parts of InfluxQL and InfluxDB line protocol. |
v2
Package client (v2) is the current official Go client for InfluxDB.
|
Package client (v2) is the current official Go client for InfluxDB. |
Click to show internal directories.
Click to hide internal directories.