README
¶
JTI OpenConfig Telemetry Input Plugin
This plugin reads Juniper Networks implementation of OpenConfig telemetry data from listed sensors using Junos Telemetry Interface. Refer to openconfig.net for more details about OpenConfig and Junos Telemetry Interface (JTI).
Configuration:
# Subscribe and receive OpenConfig Telemetry data using JTI
[[inputs.jti_openconfig_telemetry]]
## List of device addresses to collect telemetry from
servers = ["localhost:1883"]
## Authentication details. Username and password are must if device expects
## authentication. Client ID must be unique when connecting from multiple instances
## of telegraf to the same device
username = "user"
password = "pass"
client_id = "telegraf"
## Frequency to get data
sample_frequency = "1000ms"
## Sensors to subscribe for
## A identifier for each sensor can be provided in path by separating with space
## Else sensor path will be used as identifier
## When identifier is used, we can provide a list of space separated sensors.
## A single subscription will be created with all these sensors and data will
## be saved to measurement with this identifier name
sensors = [
"/interfaces/",
"collection /components/ /lldp",
]
## We allow specifying sensor group level reporting rate. To do this, specify the
## reporting rate in Duration at the beginning of sensor paths / collection
## name. For entries without reporting rate, we use configured sample frequency
sensors = [
"1000ms customReporting /interfaces /lldp",
"2000ms collection /components",
"/interfaces",
]
## x509 Certificate to use with TLS connection. If it is not provided, an insecure
## channel will be opened with server
ssl_cert = "/etc/telegraf/cert.pem"
## Delay between retry attempts of failed RPC calls or streams. Defaults to 1000ms.
## Failed streams/calls will not be retried if 0 is provided
retry_delay = "1000ms"
## To treat all string values as tags, set this to true
str_as_tags = false
Tags:
- All measurements are tagged appropriately using the identifier information in incoming data
Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CollectionByKeys ¶
type CollectionByKeys []DataGroup
Sort the data groups by number of keys
func (CollectionByKeys) Insert ¶
func (a CollectionByKeys) Insert(tags map[string]string, data map[string]interface{}) CollectionByKeys
Inserts into already existing group or creates a new group
func (CollectionByKeys) IsAvailable ¶
func (a CollectionByKeys) IsAvailable(tags map[string]string) *DataGroup
Checks to see if there is already a group with these tags and returns its index. Returns -1 if unavailable.
func (CollectionByKeys) Len ¶
func (a CollectionByKeys) Len() int
func (CollectionByKeys) Less ¶
func (a CollectionByKeys) Less(i, j int) bool
func (CollectionByKeys) Swap ¶
func (a CollectionByKeys) Swap(i, j int)
type OpenConfigTelemetry ¶
type OpenConfigTelemetry struct { Servers []string Sensors []string Username string Password string ClientID string `toml:"client_id"` SampleFrequency internal.Duration `toml:"sample_frequency"` SSLCert string `toml:"ssl_cert"` StrAsTags bool `toml:"str_as_tags"` RetryDelay internal.Duration `toml:"retry_delay"` // contains filtered or unexported fields }
func (*OpenConfigTelemetry) Description ¶
func (m *OpenConfigTelemetry) Description() string
func (*OpenConfigTelemetry) Gather ¶
func (m *OpenConfigTelemetry) Gather(acc telegraf.Accumulator) error
func (*OpenConfigTelemetry) SampleConfig ¶
func (m *OpenConfigTelemetry) SampleConfig() string
func (*OpenConfigTelemetry) Start ¶
func (m *OpenConfigTelemetry) Start(acc telegraf.Accumulator) error
func (*OpenConfigTelemetry) Stop ¶
func (m *OpenConfigTelemetry) Stop()
Click to show internal directories.
Click to hide internal directories.