SlideShare une entreprise Scribd logo
1  sur  46
Télécharger pour lire hors ligne
Noah Crowley / Developer Advocate
How to Build a Telegraf
Plugin
© 2018 InfluxData. All rights reserved.
What we’ll be covering
✔ Telegraf overview

✔ Examples of Telegraf plugins

✔ Telegraf plugin architecture

✔ How to a write a Telegraf plugin
Telegraf Overview
© 2018 InfluxData. All rights reserved.
© 2018 InfluxData. All rights reserved.
Telegraf Overview
• Telegraf is an open source, plugin-driven agent for collecting
and reporting metrics

• “Push” or “Pull”

• Large collection of plugins: 192 (as of 3/13/2019)

• Inputs: 149

• Outputs: 30

• Aggregators: 9

• Processors: 4
© 2018 InfluxData. All rights reserved.
Telegraf Overview
• Can act as:

• Agent

• Collector

• Part of an Ingest Pipeline
© 2018 InfluxData. All rights reserved.
Telegraf Plugins
• Outputs

• Allows you to send metrics to a variety of datastores

• Plugins for both InfluxDB 1.x and 2.0

• Supports Kafka, MQTT, NSQ, OpenMetrics, and more

• Aggregators and Processors allow you to manipulate data as it
flows through Telegraf

• Transform tags, convert types, calculate histograms
© 2018 InfluxData. All rights reserved.
Telegraf Input Plugins
• Metrics ingestion from host system: CPU, I/O, Network…

• Common Applications like NGINX, Postgres, Redis…

• Third Party APIs: Mailchimp, Cloudwatch, Google Analytics…

• General-Purpose Protocols: HTTP, Socket, MQTT…

• …and more!
© 2018 InfluxData. All rights reserved.
Telegraf Benefits
• Minimal memory footprint

• Tagging of metrics

• Batching of metrics to reduce the number of atomic writes

• Easy contribution of functionality thanks to Go

• Static Binary

• Strong Community Contributions
Examples of Plugins
© 2018 InfluxData. All rights reserved.
statsd
• Listens for incoming data
• Acts as a statsd instance
• Outputs to any configured output
© 2018 InfluxData. All rights reserved.
postgresql
• Collects performance data
• Uses data from built-in views:
• pg_stat_database
• pg_stat_bgwriter
© 2018 InfluxData. All rights reserved.
apache
• Connects over HTTP
• Reads data from:
• /server-status?auto
© 2018 InfluxData. All rights reserved.
win_perf_counters
• Collects performance data from
Windows machines
© 2018 InfluxData. All rights reserved.
Input Plugin Considerations
• Where does the data exist?

• How can it be collected?

• What shape is the data?
© 2018 InfluxData. All rights reserved.
prometheus_client
• Output plugin
• Exposes metrics in Prometheus
(now OpenMetrics) format.
© 2018 InfluxData. All rights reserved.
mqtt
• Output half of the MQTT plugins
• Allows you to write messages to
an MQTT broker.
© 2018 InfluxData. All rights reserved.
Output Plugin Considerations
• How should the data be shaped?

• How is the data output?

• Where is the data output to?
Plugin Architecture
© 2018 InfluxData. All rights reserved.
Plugin Architecture
• Built to be extensible from the beginning

• Make use of interfaces in Go

• Each plugin type has an interface
© 2018 InfluxData. All rights reserved.
© 2018 InfluxData. All rights reserved.
package simple
// simple.go
import (
"github.com/influxdata/telegraf"
"github.com/influxdata/telegraf/plugins/inputs"
)
type Simple struct {
Ok bool
}
func (s *Simple) Description() string {
return "a demo plugin"
}
func (s *Simple) SampleConfig() string {
return `
## Indicate if everything is fine
ok = true
`
}
func (s *Simple) Gather(acc telegraf.Accumulator) error {
if s.Ok {
acc.AddFields("state", map[string]interface{}{"value":
"pretty good"}, nil)
} else {
acc.AddFields("state", map[string]interface{}{"value":
"not great"}, nil)
}
return nil
}
func init() {
inputs.Add("simple", func() telegraf.Input { return
&Simple{} })
}
Building a Plugin
© 2018 InfluxData. All rights reserved.
Getting started…
• Recommend using Go 1.11

• Understanding of Git & Pull Requests

• What is our plugin going to do?

• Generate data using “sine” and “cosine” trigonometric
functions

• Read the CONTRIBUTING.md file to ensure you can build & test
Telegraf before continuing
© 2018 InfluxData. All rights reserved.
Getting started…
• Set up your workspace, get the code, and create a branch:

• Create the required directories and files:

• Add boilerplate…
$ go get github.com/influxdata/telegraf

$ cd $GOPATH/github.com/influxdata/telegraf

$ git checkout -b trig-demo
$ cd plugins/inputs
$ mkdir trig
$ touch trig/trig.go
© 2018 InfluxData. All rights reserved.
package trig



import (

    "github.com/influxdata/telegraf"

    "github.com/influxdata/telegraf/plugins/inputs"

)



type Trig struct {

}



func (s *Trig) SampleConfig() string {

    return ""

}



func (s *Trig) Description() string {

    return ""

}



func (s *Trig) Gather(acc telegraf.Accumulator) error {

    return nil

}



func init() {

    inputs.Add("trig", func() telegraf.Input { return &Trig{} })

}
trig.go
© 2018 InfluxData. All rights reserved.
Import your plugin
• Add the following to telegraf/plugins/inputs/all/all.go

• This will your plugin into the main Telegraf package and ensure
that it can run.
_ "github.com/influxdata/telegraf/plugins/inputs/trig"
© 2018 InfluxData. All rights reserved.
Add configuration variables
• Each plugin has a struct

• There must be a property on the struct to hold any
configuration variables

• Any other variables should be unexported

• We’ll add two variables:

• “x” will hold the state of the plugin between collection intervals

• “Amplitude” will hold the amplitude value for the sin wave
© 2018 InfluxData. All rights reserved.
package trig



import (

    "github.com/influxdata/telegraf"

    "github.com/influxdata/telegraf/plugins/inputs"

)



type Trig struct {
    x         float64
    Amplitude float64

}



func (s *Trig) SampleConfig() string {

    return ""

}



func (s *Trig) Description() string {

    return ""

}



func (s *Trig) Gather(acc telegraf.Accumulator) error {

trig.go
© 2018 InfluxData. All rights reserved.
Add sample configuration
• Telegraf can dynamically construct configuration files

• Aggregates sample configs for all plugins

• The CLI allows you to provide arguments to filter which plugins
are included

• In 2.0, InfluxDB will use this info to generate Telegraf configs
© 2018 InfluxData. All rights reserved.
package trig



import (

    "github.com/influxdata/telegraf"

    "github.com/influxdata/telegraf/plugins/inputs"

)



type Trig struct {
    x         float64
    Amplitude float64

}



var TrigConfig = `

 ## Set the amplitude

 amplitude = 10.0

`



func (s *Trig) SampleConfig() string {

    return TrigConfig

}


trig.go
© 2018 InfluxData. All rights reserved.
Add a simple description
• This description is included above the plugin configuration and
should briefly describe what your plugin does
© 2018 InfluxData. All rights reserved.
type Trig struct {
    x         float64
    Amplitude float64

}



var TrigConfig = `

 ## Set the amplitude

 amplitude = 10.0

`



func (s *Trig) SampleConfig() string {

    return TrigConfig

}


func (s *Trig) Description() string {

    return "Inserts sine and cosine waves for demonstration
purposes"

}



func (s *Trig) Gather(acc telegraf.Accumulator) error {

trig.go
© 2018 InfluxData. All rights reserved.
Test your config!
• First, build Telegraf

• Generate a config:
$ make telegraf
$ telegraf -sample-config -input-filter trig
-output-filter influxdb -debug
© 2018 InfluxData. All rights reserved.
...

###############################################################################
# INPUT PLUGINS #
###############################################################################
# Inserts sine and cosine waves for demonstration purposes
[[inputs.trig]]
## Set the amplitude
amplitude = 10.0
© 2018 InfluxData. All rights reserved.
The “Gather” function
• The heart of the plugin, it is run every time telegraf collects
metrics

• This is where you’ll do the majority of the work

• We’ll generate sine and cosine values

• At the end of the function, we add any data we’ve collected
and to the Telegraf “Accumulator” by
calling .AddFields(measurement, tags, fields). 

• This defines a new point in InfluxDB with the timestamp being
the collection time.
© 2018 InfluxData. All rights reserved.
    return "Inserts sine and cosine waves for demonstration
purposes"

}



func (s *Trig) Gather(acc telegraf.Accumulator) error {

    sinner := math.Sin((s.x*math.Pi)/5.0) * s.Amplitude

    cosinner := math.Cos((s.x*math.Pi)/5.0) * s.Amplitude



    fields := make(map[string]interface{})

    fields["sine"] = sinner

    fields["cosine"] = cosinner



    tags := make(map[string]string)



    s.x += 1.0

    acc.AddFields("trig", fields, tags)



    return nil

}
trig.go
© 2018 InfluxData. All rights reserved.
Add initial state
• In our boilerplate, we added an init() function

• Called when the plugin is first initialized

• Makes the plugin available to the Telegraf agent

• We can define starting state as part of this function

• We need to initialize our “x” variable
© 2018 InfluxData. All rights reserved.
    cosinner := math.Cos((s.x*math.Pi)/5.0) * s.Amplitude



    fields := make(map[string]interface{})

    fields["sine"] = sinner

    fields["cosine"] = cosinner



    tags := make(map[string]string)



    s.x += 1.0

    acc.AddFields("trig", fields, tags)



    return nil

}




func init() {
    inputs.Add("trig", func() telegraf.Input { return &Trig{x: 0.0} })
}
trig.go
© 2018 InfluxData. All rights reserved.
Compile and test
• Once again, build Telegraf:

• Generate a config and write it to a file:
$ make telegraf
$ ./telegraf -sample-config -input-filter
trig -output-filter influxdb -debug >>
telegraf.conf.test
• Run Telegraf with the new config:
$ ./telegraf -config telegraf.conf.test
-debug
© 2018 InfluxData. All rights reserved.
$ ./telegraf -config telegraf.conf.test -debug
2019-03-14T06:32:12Z I! Starting Telegraf
2019-03-14T06:32:12Z I! Loaded inputs: trig
2019-03-14T06:32:12Z I! Loaded aggregators:
2019-03-14T06:32:12Z I! Loaded processors:
2019-03-14T06:32:12Z I! Loaded outputs: influxdb
2019-03-14T06:32:12Z I! Tags enabled: host=noah-mbp.local
2019-03-14T06:32:12Z I! [agent] Config: Interval:10s, Quiet:false,
Hostname:"noah-mbp.local", Flush Interval:10s
2019-03-14T06:32:12Z D! [agent] Connecting outputs
2019-03-14T06:32:12Z D! [agent] Attempting connection to output: influxdb
2019-03-14T06:32:12Z D! [agent] Successfully connected to output: influxdb
2019-03-14T06:32:12Z D! [agent] Starting service inputs
2019-03-14T06:32:30Z D! [outputs.influxdb] wrote batch of 1 metrics in
23.857525ms
2019-03-14T06:32:30Z D! [outputs.influxdb] buffer fullness: 1 / 10000 metrics.
© 2018 InfluxData. All rights reserved.
Final steps before submitting
• Add a few things to your plugin…

• a README.md

• a LICENSE

• A sample of the input/output format

• Tests!
© 2018 InfluxData. All rights reserved.
package trig



import (

    "math"

    "testing"

    "github.com/influxdata/telegraf/testutil"

)



func TestTrig(t *testing.T) {



    s := &Trig{



        Amplitude: 10.0,

    }



    for i := 0.0; i < 10.0; i++ {

        var acc testutil.Accumulator

        sine := math.Sin((i*math.Pi)/5.0) * s.Amplitude

        cosine := math.Cos((i*math.Pi)/5.0) * s.Amplitude

        s.Gather(&acc)

        fields := make(map[string]interface{})

        fields["sine"] = sine

        fields["cosine"] = cosine



        acc.AssertContainsFields(t, "trig", fields)



    }



}
trig_test.go
© 2018 InfluxData. All rights reserved.
Final steps before submitting
• Add a few things to your plugin…

• a README.md

• a LICENSE

• A sample of the input/output format

• Tests!

• …and submit! 

• github.com/influxdata/telegraf/pulls
Thank You!

Contenu connexe

Tendances

Grafana introduction
Grafana introductionGrafana introduction
Grafana introductionRico Chen
 
Prometheus - basics
Prometheus - basicsPrometheus - basics
Prometheus - basicsJuraj Hantak
 
Getting Started Monitoring with Prometheus and Grafana
Getting Started Monitoring with Prometheus and GrafanaGetting Started Monitoring with Prometheus and Grafana
Getting Started Monitoring with Prometheus and GrafanaSyah Dwi Prihatmoko
 
Monitoring With Prometheus
Monitoring With PrometheusMonitoring With Prometheus
Monitoring With PrometheusKnoldus Inc.
 
OpenTelemetry For Architects
OpenTelemetry For ArchitectsOpenTelemetry For Architects
OpenTelemetry For ArchitectsKevin Brockhoff
 
Migrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDI
Migrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDIMigrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDI
Migrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDIMario-Leander Reimer
 
Gitops: the kubernetes way
Gitops: the kubernetes wayGitops: the kubernetes way
Gitops: the kubernetes waysparkfabrik
 
Server monitoring using grafana and prometheus
Server monitoring using grafana and prometheusServer monitoring using grafana and prometheus
Server monitoring using grafana and prometheusCeline George
 
Backstage at CNCF Madison.pptx
Backstage at CNCF Madison.pptxBackstage at CNCF Madison.pptx
Backstage at CNCF Madison.pptxBrandenTimm1
 
Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...LibbySchulze
 
Monitoring using Prometheus and Grafana
Monitoring using Prometheus and GrafanaMonitoring using Prometheus and Grafana
Monitoring using Prometheus and GrafanaArvind Kumar G.S
 
Exploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on KubernetesExploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on KubernetesRed Hat Developers
 
OpenTelemetry Introduction
OpenTelemetry Introduction OpenTelemetry Introduction
OpenTelemetry Introduction DimitrisFinas1
 
OSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdf
OSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdfOSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdf
OSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdfNETWAYS
 
Terraform modules and best-practices - September 2018
Terraform modules and best-practices - September 2018Terraform modules and best-practices - September 2018
Terraform modules and best-practices - September 2018Anton Babenko
 

Tendances (20)

Grafana introduction
Grafana introductionGrafana introduction
Grafana introduction
 
Prometheus and Grafana
Prometheus and GrafanaPrometheus and Grafana
Prometheus and Grafana
 
Prometheus - basics
Prometheus - basicsPrometheus - basics
Prometheus - basics
 
Getting Started Monitoring with Prometheus and Grafana
Getting Started Monitoring with Prometheus and GrafanaGetting Started Monitoring with Prometheus and Grafana
Getting Started Monitoring with Prometheus and Grafana
 
Cloud Monitoring tool Grafana
Cloud Monitoring  tool Grafana Cloud Monitoring  tool Grafana
Cloud Monitoring tool Grafana
 
Monitoring With Prometheus
Monitoring With PrometheusMonitoring With Prometheus
Monitoring With Prometheus
 
OpenTelemetry For Architects
OpenTelemetry For ArchitectsOpenTelemetry For Architects
OpenTelemetry For Architects
 
Migrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDI
Migrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDIMigrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDI
Migrating a JSF-Based Web Application from Spring 3 to Java EE 7 and CDI
 
Gitops: the kubernetes way
Gitops: the kubernetes wayGitops: the kubernetes way
Gitops: the kubernetes way
 
Server monitoring using grafana and prometheus
Server monitoring using grafana and prometheusServer monitoring using grafana and prometheus
Server monitoring using grafana and prometheus
 
Backstage at CNCF Madison.pptx
Backstage at CNCF Madison.pptxBackstage at CNCF Madison.pptx
Backstage at CNCF Madison.pptx
 
Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...
 
ELK Stack
ELK StackELK Stack
ELK Stack
 
Monitoring using Prometheus and Grafana
Monitoring using Prometheus and GrafanaMonitoring using Prometheus and Grafana
Monitoring using Prometheus and Grafana
 
Exploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on KubernetesExploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on Kubernetes
 
Terraform
TerraformTerraform
Terraform
 
OpenTelemetry Introduction
OpenTelemetry Introduction OpenTelemetry Introduction
OpenTelemetry Introduction
 
OSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdf
OSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdfOSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdf
OSMC 2022 | OpenTelemetry 101 by Dotan Horovit s.pdf
 
Prometheus with Grafana - AddWeb Solution
Prometheus with Grafana - AddWeb SolutionPrometheus with Grafana - AddWeb Solution
Prometheus with Grafana - AddWeb Solution
 
Terraform modules and best-practices - September 2018
Terraform modules and best-practices - September 2018Terraform modules and best-practices - September 2018
Terraform modules and best-practices - September 2018
 

Similaire à How to Build a Telegraf Plugin by Noah Crowley

Sensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxData
Sensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxDataSensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxData
Sensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxDataInfluxData
 
How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...
How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...
How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...InfluxData
 
Finding OOMS in Legacy Systems with the Syslog Telegraf Plugin
Finding OOMS in Legacy Systems with the Syslog Telegraf PluginFinding OOMS in Legacy Systems with the Syslog Telegraf Plugin
Finding OOMS in Legacy Systems with the Syslog Telegraf PluginInfluxData
 
Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...
Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...
Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...InfluxData
 
Webinar - Building Custom Extensions With AppDynamics
Webinar - Building Custom Extensions With AppDynamicsWebinar - Building Custom Extensions With AppDynamics
Webinar - Building Custom Extensions With AppDynamicsTodd Radel
 
Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...
Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...
Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...InfluxData
 
Python and trending_data_ops
Python and trending_data_opsPython and trending_data_ops
Python and trending_data_opschase pettet
 
INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...
INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...
INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...apidays
 
P4 Introduction
P4 Introduction P4 Introduction
P4 Introduction Netronome
 
The Flink - Apache Bigtop integration
The Flink - Apache Bigtop integrationThe Flink - Apache Bigtop integration
The Flink - Apache Bigtop integrationMárton Balassi
 
Sam Dillard [InfluxData] | Performance Optimization in InfluxDB | InfluxDays...
Sam Dillard [InfluxData] | Performance Optimization in InfluxDB  | InfluxDays...Sam Dillard [InfluxData] | Performance Optimization in InfluxDB  | InfluxDays...
Sam Dillard [InfluxData] | Performance Optimization in InfluxDB | InfluxDays...InfluxData
 
InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...
InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...
InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...InfluxData
 
Why Open Source Works for DevOps Monitoring
Why Open Source Works for DevOps MonitoringWhy Open Source Works for DevOps Monitoring
Why Open Source Works for DevOps MonitoringDevOps.com
 
Helm Charts Security 101
Helm Charts Security 101Helm Charts Security 101
Helm Charts Security 101Deep Datta
 
Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...
Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...
Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...InfluxData
 
Monitoring InfluxEnterprise
Monitoring InfluxEnterpriseMonitoring InfluxEnterprise
Monitoring InfluxEnterpriseInfluxData
 
Taming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafTaming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafInfluxData
 
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022InfluxData
 
Taming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafTaming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafInfluxData
 
Intro to InfluxDB 2.0 and Your First Flux Query by Sonia Gupta
Intro to InfluxDB 2.0 and Your First Flux Query by Sonia GuptaIntro to InfluxDB 2.0 and Your First Flux Query by Sonia Gupta
Intro to InfluxDB 2.0 and Your First Flux Query by Sonia GuptaInfluxData
 

Similaire à How to Build a Telegraf Plugin by Noah Crowley (20)

Sensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxData
Sensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxDataSensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxData
Sensor Data in InfluxDB by David Simmons, IoT Developer Evangelist | InfluxData
 
How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...
How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...
How to Introduce Telemetry Streaming (gNMI) in Your Network with SNMP with Te...
 
Finding OOMS in Legacy Systems with the Syslog Telegraf Plugin
Finding OOMS in Legacy Systems with the Syslog Telegraf PluginFinding OOMS in Legacy Systems with the Syslog Telegraf Plugin
Finding OOMS in Legacy Systems with the Syslog Telegraf Plugin
 
Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...
Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...
Nicolas Steinmetz [CérénIT] | Sustain Your Observability from Bare Metal TICK...
 
Webinar - Building Custom Extensions With AppDynamics
Webinar - Building Custom Extensions With AppDynamicsWebinar - Building Custom Extensions With AppDynamics
Webinar - Building Custom Extensions With AppDynamics
 
Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...
Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...
Anais Dotis-Georgiou & Faith Chikwekwe [InfluxData] | Top 10 Hurdles for Flux...
 
Python and trending_data_ops
Python and trending_data_opsPython and trending_data_ops
Python and trending_data_ops
 
INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...
INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...
INTERFACE by apidays 2023 - Data Collection Basics, Anais Dotis-Georgiou, Inf...
 
P4 Introduction
P4 Introduction P4 Introduction
P4 Introduction
 
The Flink - Apache Bigtop integration
The Flink - Apache Bigtop integrationThe Flink - Apache Bigtop integration
The Flink - Apache Bigtop integration
 
Sam Dillard [InfluxData] | Performance Optimization in InfluxDB | InfluxDays...
Sam Dillard [InfluxData] | Performance Optimization in InfluxDB  | InfluxDays...Sam Dillard [InfluxData] | Performance Optimization in InfluxDB  | InfluxDays...
Sam Dillard [InfluxData] | Performance Optimization in InfluxDB | InfluxDays...
 
InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...
InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...
InfluxDB 101 – Concepts and Architecture by Michael DeSa, Software Engineer |...
 
Why Open Source Works for DevOps Monitoring
Why Open Source Works for DevOps MonitoringWhy Open Source Works for DevOps Monitoring
Why Open Source Works for DevOps Monitoring
 
Helm Charts Security 101
Helm Charts Security 101Helm Charts Security 101
Helm Charts Security 101
 
Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...
Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...
Lessons Learned Running InfluxDB Cloud and Other Cloud Services at Scale by T...
 
Monitoring InfluxEnterprise
Monitoring InfluxEnterpriseMonitoring InfluxEnterprise
Monitoring InfluxEnterprise
 
Taming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafTaming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using Telegraf
 
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
 
Taming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafTaming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using Telegraf
 
Intro to InfluxDB 2.0 and Your First Flux Query by Sonia Gupta
Intro to InfluxDB 2.0 and Your First Flux Query by Sonia GuptaIntro to InfluxDB 2.0 and Your First Flux Query by Sonia Gupta
Intro to InfluxDB 2.0 and Your First Flux Query by Sonia Gupta
 

Plus de InfluxData

Announcing InfluxDB Clustered
Announcing InfluxDB ClusteredAnnouncing InfluxDB Clustered
Announcing InfluxDB ClusteredInfluxData
 
Best Practices for Leveraging the Apache Arrow Ecosystem
Best Practices for Leveraging the Apache Arrow EcosystemBest Practices for Leveraging the Apache Arrow Ecosystem
Best Practices for Leveraging the Apache Arrow EcosystemInfluxData
 
How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...
How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...
How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...InfluxData
 
Power Your Predictive Analytics with InfluxDB
Power Your Predictive Analytics with InfluxDBPower Your Predictive Analytics with InfluxDB
Power Your Predictive Analytics with InfluxDBInfluxData
 
How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base
How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base
How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base InfluxData
 
Build an Edge-to-Cloud Solution with the MING Stack
Build an Edge-to-Cloud Solution with the MING StackBuild an Edge-to-Cloud Solution with the MING Stack
Build an Edge-to-Cloud Solution with the MING StackInfluxData
 
Meet the Founders: An Open Discussion About Rewriting Using Rust
Meet the Founders: An Open Discussion About Rewriting Using RustMeet the Founders: An Open Discussion About Rewriting Using Rust
Meet the Founders: An Open Discussion About Rewriting Using RustInfluxData
 
Introducing InfluxDB Cloud Dedicated
Introducing InfluxDB Cloud DedicatedIntroducing InfluxDB Cloud Dedicated
Introducing InfluxDB Cloud DedicatedInfluxData
 
Gain Better Observability with OpenTelemetry and InfluxDB
Gain Better Observability with OpenTelemetry and InfluxDB Gain Better Observability with OpenTelemetry and InfluxDB
Gain Better Observability with OpenTelemetry and InfluxDB InfluxData
 
How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...
How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...
How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...InfluxData
 
How Delft University's Engineering Students Make Their EV Formula-Style Race ...
How Delft University's Engineering Students Make Their EV Formula-Style Race ...How Delft University's Engineering Students Make Their EV Formula-Style Race ...
How Delft University's Engineering Students Make Their EV Formula-Style Race ...InfluxData
 
Introducing InfluxDB’s New Time Series Database Storage Engine
Introducing InfluxDB’s New Time Series Database Storage EngineIntroducing InfluxDB’s New Time Series Database Storage Engine
Introducing InfluxDB’s New Time Series Database Storage EngineInfluxData
 
Start Automating InfluxDB Deployments at the Edge with balena
Start Automating InfluxDB Deployments at the Edge with balena Start Automating InfluxDB Deployments at the Edge with balena
Start Automating InfluxDB Deployments at the Edge with balena InfluxData
 
Understanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage EngineUnderstanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage EngineInfluxData
 
Streamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDB
Streamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDBStreamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDB
Streamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDBInfluxData
 
Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...
Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...
Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...InfluxData
 
Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022
Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022
Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022InfluxData
 
Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022InfluxData
 
Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...
Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...
Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...InfluxData
 
Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022InfluxData
 

Plus de InfluxData (20)

Announcing InfluxDB Clustered
Announcing InfluxDB ClusteredAnnouncing InfluxDB Clustered
Announcing InfluxDB Clustered
 
Best Practices for Leveraging the Apache Arrow Ecosystem
Best Practices for Leveraging the Apache Arrow EcosystemBest Practices for Leveraging the Apache Arrow Ecosystem
Best Practices for Leveraging the Apache Arrow Ecosystem
 
How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...
How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...
How Bevi Uses InfluxDB and Grafana to Improve Predictive Maintenance and Redu...
 
Power Your Predictive Analytics with InfluxDB
Power Your Predictive Analytics with InfluxDBPower Your Predictive Analytics with InfluxDB
Power Your Predictive Analytics with InfluxDB
 
How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base
How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base
How Teréga Replaces Legacy Data Historians with InfluxDB, AWS and IO-Base
 
Build an Edge-to-Cloud Solution with the MING Stack
Build an Edge-to-Cloud Solution with the MING StackBuild an Edge-to-Cloud Solution with the MING Stack
Build an Edge-to-Cloud Solution with the MING Stack
 
Meet the Founders: An Open Discussion About Rewriting Using Rust
Meet the Founders: An Open Discussion About Rewriting Using RustMeet the Founders: An Open Discussion About Rewriting Using Rust
Meet the Founders: An Open Discussion About Rewriting Using Rust
 
Introducing InfluxDB Cloud Dedicated
Introducing InfluxDB Cloud DedicatedIntroducing InfluxDB Cloud Dedicated
Introducing InfluxDB Cloud Dedicated
 
Gain Better Observability with OpenTelemetry and InfluxDB
Gain Better Observability with OpenTelemetry and InfluxDB Gain Better Observability with OpenTelemetry and InfluxDB
Gain Better Observability with OpenTelemetry and InfluxDB
 
How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...
How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...
How a Heat Treating Plant Ensures Tight Process Control and Exceptional Quali...
 
How Delft University's Engineering Students Make Their EV Formula-Style Race ...
How Delft University's Engineering Students Make Their EV Formula-Style Race ...How Delft University's Engineering Students Make Their EV Formula-Style Race ...
How Delft University's Engineering Students Make Their EV Formula-Style Race ...
 
Introducing InfluxDB’s New Time Series Database Storage Engine
Introducing InfluxDB’s New Time Series Database Storage EngineIntroducing InfluxDB’s New Time Series Database Storage Engine
Introducing InfluxDB’s New Time Series Database Storage Engine
 
Start Automating InfluxDB Deployments at the Edge with balena
Start Automating InfluxDB Deployments at the Edge with balena Start Automating InfluxDB Deployments at the Edge with balena
Start Automating InfluxDB Deployments at the Edge with balena
 
Understanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage EngineUnderstanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage Engine
 
Streamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDB
Streamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDBStreamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDB
Streamline and Scale Out Data Pipelines with Kubernetes, Telegraf, and InfluxDB
 
Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...
Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...
Ward Bowman [PTC] | ThingWorx Long-Term Data Storage with InfluxDB | InfluxDa...
 
Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022
Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022
Scott Anderson [InfluxData] | New & Upcoming Flux Features | InfluxDays 2022
 
Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts | InfluxDays 2022
 
Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...
Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...
Steinkamp, Clifford [InfluxData] | Welcome to InfluxDays 2022 - Day 2 | Influ...
 
Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022
Steinkamp, Clifford [InfluxData] | Closing Thoughts Day 1 | InfluxDays 2022
 

Dernier

Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rick Flair
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 

Dernier (20)

Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 

How to Build a Telegraf Plugin by Noah Crowley

  • 1. Noah Crowley / Developer Advocate How to Build a Telegraf Plugin
  • 2. © 2018 InfluxData. All rights reserved. What we’ll be covering ✔ Telegraf overview ✔ Examples of Telegraf plugins ✔ Telegraf plugin architecture ✔ How to a write a Telegraf plugin
  • 4. © 2018 InfluxData. All rights reserved.
  • 5. © 2018 InfluxData. All rights reserved. Telegraf Overview • Telegraf is an open source, plugin-driven agent for collecting and reporting metrics • “Push” or “Pull” • Large collection of plugins: 192 (as of 3/13/2019) • Inputs: 149 • Outputs: 30 • Aggregators: 9 • Processors: 4
  • 6. © 2018 InfluxData. All rights reserved. Telegraf Overview • Can act as: • Agent • Collector • Part of an Ingest Pipeline
  • 7. © 2018 InfluxData. All rights reserved. Telegraf Plugins • Outputs • Allows you to send metrics to a variety of datastores • Plugins for both InfluxDB 1.x and 2.0 • Supports Kafka, MQTT, NSQ, OpenMetrics, and more • Aggregators and Processors allow you to manipulate data as it flows through Telegraf • Transform tags, convert types, calculate histograms
  • 8. © 2018 InfluxData. All rights reserved. Telegraf Input Plugins • Metrics ingestion from host system: CPU, I/O, Network… • Common Applications like NGINX, Postgres, Redis… • Third Party APIs: Mailchimp, Cloudwatch, Google Analytics… • General-Purpose Protocols: HTTP, Socket, MQTT… • …and more!
  • 9. © 2018 InfluxData. All rights reserved. Telegraf Benefits • Minimal memory footprint • Tagging of metrics • Batching of metrics to reduce the number of atomic writes • Easy contribution of functionality thanks to Go • Static Binary • Strong Community Contributions
  • 11. © 2018 InfluxData. All rights reserved. statsd • Listens for incoming data • Acts as a statsd instance • Outputs to any configured output
  • 12. © 2018 InfluxData. All rights reserved. postgresql • Collects performance data • Uses data from built-in views: • pg_stat_database • pg_stat_bgwriter
  • 13. © 2018 InfluxData. All rights reserved. apache • Connects over HTTP • Reads data from: • /server-status?auto
  • 14. © 2018 InfluxData. All rights reserved. win_perf_counters • Collects performance data from Windows machines
  • 15. © 2018 InfluxData. All rights reserved. Input Plugin Considerations • Where does the data exist? • How can it be collected? • What shape is the data?
  • 16. © 2018 InfluxData. All rights reserved. prometheus_client • Output plugin • Exposes metrics in Prometheus (now OpenMetrics) format.
  • 17. © 2018 InfluxData. All rights reserved. mqtt • Output half of the MQTT plugins • Allows you to write messages to an MQTT broker.
  • 18. © 2018 InfluxData. All rights reserved. Output Plugin Considerations • How should the data be shaped? • How is the data output? • Where is the data output to?
  • 20. © 2018 InfluxData. All rights reserved. Plugin Architecture • Built to be extensible from the beginning • Make use of interfaces in Go • Each plugin type has an interface
  • 21. © 2018 InfluxData. All rights reserved.
  • 22. © 2018 InfluxData. All rights reserved. package simple // simple.go import ( "github.com/influxdata/telegraf" "github.com/influxdata/telegraf/plugins/inputs" ) type Simple struct { Ok bool } func (s *Simple) Description() string { return "a demo plugin" } func (s *Simple) SampleConfig() string { return ` ## Indicate if everything is fine ok = true ` } func (s *Simple) Gather(acc telegraf.Accumulator) error { if s.Ok { acc.AddFields("state", map[string]interface{}{"value": "pretty good"}, nil) } else { acc.AddFields("state", map[string]interface{}{"value": "not great"}, nil) } return nil } func init() { inputs.Add("simple", func() telegraf.Input { return &Simple{} }) }
  • 24. © 2018 InfluxData. All rights reserved. Getting started… • Recommend using Go 1.11 • Understanding of Git & Pull Requests • What is our plugin going to do? • Generate data using “sine” and “cosine” trigonometric functions • Read the CONTRIBUTING.md file to ensure you can build & test Telegraf before continuing
  • 25. © 2018 InfluxData. All rights reserved. Getting started… • Set up your workspace, get the code, and create a branch: • Create the required directories and files: • Add boilerplate… $ go get github.com/influxdata/telegraf
 $ cd $GOPATH/github.com/influxdata/telegraf
 $ git checkout -b trig-demo $ cd plugins/inputs $ mkdir trig $ touch trig/trig.go
  • 26. © 2018 InfluxData. All rights reserved. package trig
 
 import (
     "github.com/influxdata/telegraf"
     "github.com/influxdata/telegraf/plugins/inputs"
 )
 
 type Trig struct {
 }
 
 func (s *Trig) SampleConfig() string {
     return ""
 }
 
 func (s *Trig) Description() string {
     return ""
 }
 
 func (s *Trig) Gather(acc telegraf.Accumulator) error {
     return nil
 }
 
 func init() {
     inputs.Add("trig", func() telegraf.Input { return &Trig{} })
 } trig.go
  • 27. © 2018 InfluxData. All rights reserved. Import your plugin • Add the following to telegraf/plugins/inputs/all/all.go • This will your plugin into the main Telegraf package and ensure that it can run. _ "github.com/influxdata/telegraf/plugins/inputs/trig"
  • 28. © 2018 InfluxData. All rights reserved. Add configuration variables • Each plugin has a struct • There must be a property on the struct to hold any configuration variables • Any other variables should be unexported • We’ll add two variables: • “x” will hold the state of the plugin between collection intervals • “Amplitude” will hold the amplitude value for the sin wave
  • 29. © 2018 InfluxData. All rights reserved. package trig
 
 import (
     "github.com/influxdata/telegraf"
     "github.com/influxdata/telegraf/plugins/inputs"
 )
 
 type Trig struct {     x         float64     Amplitude float64
 }
 
 func (s *Trig) SampleConfig() string {
     return ""
 }
 
 func (s *Trig) Description() string {
     return ""
 }
 
 func (s *Trig) Gather(acc telegraf.Accumulator) error {
 trig.go
  • 30. © 2018 InfluxData. All rights reserved. Add sample configuration • Telegraf can dynamically construct configuration files • Aggregates sample configs for all plugins • The CLI allows you to provide arguments to filter which plugins are included • In 2.0, InfluxDB will use this info to generate Telegraf configs
  • 31. © 2018 InfluxData. All rights reserved. package trig
 
 import (
     "github.com/influxdata/telegraf"
     "github.com/influxdata/telegraf/plugins/inputs"
 )
 
 type Trig struct {     x         float64     Amplitude float64
 }
 
 var TrigConfig = `
  ## Set the amplitude
  amplitude = 10.0
 `
 
 func (s *Trig) SampleConfig() string {
     return TrigConfig
 } 
 trig.go
  • 32. © 2018 InfluxData. All rights reserved. Add a simple description • This description is included above the plugin configuration and should briefly describe what your plugin does
  • 33. © 2018 InfluxData. All rights reserved. type Trig struct {     x         float64     Amplitude float64
 }
 
 var TrigConfig = `
  ## Set the amplitude
  amplitude = 10.0
 `
 
 func (s *Trig) SampleConfig() string {
     return TrigConfig
 } 
 func (s *Trig) Description() string {
     return "Inserts sine and cosine waves for demonstration purposes"
 }
 
 func (s *Trig) Gather(acc telegraf.Accumulator) error {
 trig.go
  • 34. © 2018 InfluxData. All rights reserved. Test your config! • First, build Telegraf • Generate a config: $ make telegraf $ telegraf -sample-config -input-filter trig -output-filter influxdb -debug
  • 35. © 2018 InfluxData. All rights reserved. ...
 ############################################################################### # INPUT PLUGINS # ############################################################################### # Inserts sine and cosine waves for demonstration purposes [[inputs.trig]] ## Set the amplitude amplitude = 10.0
  • 36. © 2018 InfluxData. All rights reserved. The “Gather” function • The heart of the plugin, it is run every time telegraf collects metrics • This is where you’ll do the majority of the work • We’ll generate sine and cosine values • At the end of the function, we add any data we’ve collected and to the Telegraf “Accumulator” by calling .AddFields(measurement, tags, fields). • This defines a new point in InfluxDB with the timestamp being the collection time.
  • 37. © 2018 InfluxData. All rights reserved.     return "Inserts sine and cosine waves for demonstration purposes"
 }
 
 func (s *Trig) Gather(acc telegraf.Accumulator) error {
     sinner := math.Sin((s.x*math.Pi)/5.0) * s.Amplitude
     cosinner := math.Cos((s.x*math.Pi)/5.0) * s.Amplitude
 
     fields := make(map[string]interface{})
     fields["sine"] = sinner
     fields["cosine"] = cosinner
 
     tags := make(map[string]string)
 
     s.x += 1.0
     acc.AddFields("trig", fields, tags)
 
     return nil
 } trig.go
  • 38. © 2018 InfluxData. All rights reserved. Add initial state • In our boilerplate, we added an init() function • Called when the plugin is first initialized • Makes the plugin available to the Telegraf agent • We can define starting state as part of this function • We need to initialize our “x” variable
  • 39. © 2018 InfluxData. All rights reserved.     cosinner := math.Cos((s.x*math.Pi)/5.0) * s.Amplitude
 
     fields := make(map[string]interface{})
     fields["sine"] = sinner
     fields["cosine"] = cosinner
 
     tags := make(map[string]string)
 
     s.x += 1.0
     acc.AddFields("trig", fields, tags)
 
     return nil
 } 
 
 func init() {     inputs.Add("trig", func() telegraf.Input { return &Trig{x: 0.0} }) } trig.go
  • 40. © 2018 InfluxData. All rights reserved. Compile and test • Once again, build Telegraf: • Generate a config and write it to a file: $ make telegraf $ ./telegraf -sample-config -input-filter trig -output-filter influxdb -debug >> telegraf.conf.test • Run Telegraf with the new config: $ ./telegraf -config telegraf.conf.test -debug
  • 41. © 2018 InfluxData. All rights reserved. $ ./telegraf -config telegraf.conf.test -debug 2019-03-14T06:32:12Z I! Starting Telegraf 2019-03-14T06:32:12Z I! Loaded inputs: trig 2019-03-14T06:32:12Z I! Loaded aggregators: 2019-03-14T06:32:12Z I! Loaded processors: 2019-03-14T06:32:12Z I! Loaded outputs: influxdb 2019-03-14T06:32:12Z I! Tags enabled: host=noah-mbp.local 2019-03-14T06:32:12Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:"noah-mbp.local", Flush Interval:10s 2019-03-14T06:32:12Z D! [agent] Connecting outputs 2019-03-14T06:32:12Z D! [agent] Attempting connection to output: influxdb 2019-03-14T06:32:12Z D! [agent] Successfully connected to output: influxdb 2019-03-14T06:32:12Z D! [agent] Starting service inputs 2019-03-14T06:32:30Z D! [outputs.influxdb] wrote batch of 1 metrics in 23.857525ms 2019-03-14T06:32:30Z D! [outputs.influxdb] buffer fullness: 1 / 10000 metrics.
  • 42.
  • 43. © 2018 InfluxData. All rights reserved. Final steps before submitting • Add a few things to your plugin… • a README.md • a LICENSE • A sample of the input/output format • Tests!
  • 44. © 2018 InfluxData. All rights reserved. package trig
 
 import (
     "math"
     "testing"
     "github.com/influxdata/telegraf/testutil"
 )
 
 func TestTrig(t *testing.T) {
 
     s := &Trig{
 
         Amplitude: 10.0,
     }
 
     for i := 0.0; i < 10.0; i++ {
         var acc testutil.Accumulator
         sine := math.Sin((i*math.Pi)/5.0) * s.Amplitude
         cosine := math.Cos((i*math.Pi)/5.0) * s.Amplitude
         s.Gather(&acc)
         fields := make(map[string]interface{})
         fields["sine"] = sine
         fields["cosine"] = cosine
 
         acc.AssertContainsFields(t, "trig", fields)
 
     }
 
 } trig_test.go
  • 45. © 2018 InfluxData. All rights reserved. Final steps before submitting • Add a few things to your plugin… • a README.md • a LICENSE • A sample of the input/output format • Tests! • …and submit! • github.com/influxdata/telegraf/pulls