SlideShare une entreprise Scribd logo
1  sur  27
Télécharger pour lire hors ligne
Collecting metrics with
Graphite and StatsD
Víctor Martínez
@knoopx
http://github.com/knoopx
http://knoopx.net
What is Graphite?
What is Graphite?
An all-in-one solution for storing and visualizing
realtime time-series data in an efficient manner.
Key features:
Efficient storage and ultra-fast retrieval.
http://graphite.wikidot.com/
Graphite Architecture
Graphite Web
The frontend of
Graphite. It provides a
dashboard for retrieval
and visualization of our
metrics and a powerful
plotting API.
Carbon
The core of Graphite. It
consists of set of three
processes that take
care of receiving
incoming data,
aggregating it and
persisting it to disk.
Whisper
The current (stable)
data persistence
storage; an efficient
time-series based
database.
* There's a new persistence
layer called Ceres in the
works
Feeding in your data
PORT=2003
SERVER=graphite.your.org
echo "stats.app.logins.count 1 `date +%s`" | nc ${SERVER} ${PORT};
PORT=2003
SERVER=graphite.your.org
echo "stats.app.logins.count 1 `date +%s`" | nc ${SERVER} ${PORT};
PORT=2003
SERVER=graphite.your.org
echo "stats.app.logins.count 1 `date +%s`" | nc ${SERVER} ${PORT};
schema.application_name.namespace.metric_name.metric_type
Value
Name
Timestamp
Understanding how Carbon works
storage-schemas.conf
Allows you to define how your data
should be persisted (retention rules)
and in which order (priority).
storage-aggregation.conf
Allows you to define how your
metrics should be aggregated.
Key configuration files
Understanding how Carbon works
storage-schemas.conf
What does retention mean?
In a timespan of X time, in how much granularity I
want to store my data
Understanding how Carbon works
storage-schemas.conf
● For a timespan of 6 hours I want to store my data in
intervals of 10 seconds.
● For a timespan of 7 days I want to store my data in
intervals of 1 minute.
● For a timespan of 1 year I want to store my data in
intervals of 1 hour.
● For a timespan of 5 year I want to store my data in
intervals of 24 hours.
Understanding how Carbon works
storage-schemas.conf
Understanding how Carbon works
storage-aggregation.conf
Some examples:
stats.app.users.logins.count
stats.app.emails.sent.count
stats.app.orders.amount.max
stats.app.orders.amount.min
stats.app.response.time
Understanding how Carbon works
storage-aggregation.conf
Understanding how Carbon works
Carbon limitations
What happens if I send two metrics at
the same timespan (1h)?
1 new user – 6 minutes ago
2 new users – 5 minutes ago
Understanding how Carbon works
Carbon limitations
Carbon discards everything
but the last one
2 users
Understanding how Carbon works
Carbon limitations
● Increase schema retention: 1s:12h,[...]
and never, ever, push metrics older than
12 hours/push more than once per
second
● Pre-aggregate your data before pushing
● Use StatsD
Possible Solutions:
Understanding how Carbon works
Pre-aggregate your data
https://gist.github.com/knoopx/4738209
Understanding how Carbon works
Use StatsD
What is StatdD?
A network daemon that runs on the Node.js platform
and listens for statistics, like counters and timers, sent
over UDP and sends aggregates to one or more
pluggable backend services (e.g., Graphite).
Key features: Aggregates the data for us, fire and
forget communication protocol (UDP)
https://github.com/etsy/statsd/
Understanding how Carbon works
https://github.com/Shopify/statsd-instrument
StatsD.increment('revenue', 23.99)
StatsD.measure('worker.time') do
Worker.perform(value)
end
StatsD Instrument Gem
Important: Carefully read StatsD documentation and
ensure that your Carbon configuration explicitly
matches StatsD naming conventions
Visualizing your metrics
Using the Graphite dashboard
Common functions:
● summarize
● timeShift
● keepLastValue
● integral
● drawAsInfinite
● sumSeries
● alias
● aliasByNode
Full Documentation: http://graphite.readthedocs.
org/en/1.0/functions.html
Visualizing your metrics
Using the Graphite dashboard
Time-shifting and aliasing:
alias(timeShift(camaloon.sidekiq.workers.success.count,"24h"),"Yesterday")
alias(camaloon.sidekiq.workers.success.count,"Today")
Visualizing your metrics
Using the Graphite dashboard
Summarizing data:
summarize(camaloon.sidekiq.workers.success.count,"1h")
1h
Visualizing your metrics
Using the Graphite dashboard
Aliasing and combining series:
aliasByNode(camaloon.sidekiq.workers.*.count, 3)
Visualizing your metrics
Tasseo https://github.com/obfuscurity/tasseo
Cubism.js https://github.com/square/cubism
Visualizing your metrics
Graphene https://github.com/jondot/graphene
Visualizing your metrics
Your own solution
/render/?target=camaloon.users.count&format=json
We internally use Highchart Highstock
Other resources
Deployment
https://github.com/manasg/chef-graphite
https://github.com/gingerlime/graphite-fabric
https://github.com/knoopx/puppet-graphite
http://warwickp.com/2012/03/vagrant-box-with-graphite-statsd-gdash-nginx
https://github.com/obfuscurity/backstop
Learning
http://obfuscurity.com/Tags/Graphite
Questions?

Contenu connexe

Tendances

Introduction to Prometheus
Introduction to PrometheusIntroduction to Prometheus
Introduction to PrometheusJulien Pivotto
 
Monitoring with Prometheus
Monitoring with PrometheusMonitoring with Prometheus
Monitoring with PrometheusShiao-An Yuan
 
Systems Monitoring with Prometheus (Devops Ireland April 2015)
Systems Monitoring with Prometheus (Devops Ireland April 2015)Systems Monitoring with Prometheus (Devops Ireland April 2015)
Systems Monitoring with Prometheus (Devops Ireland April 2015)Brian Brazil
 
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)Brian Brazil
 
An Introduction to Prometheus
An Introduction to PrometheusAn Introduction to Prometheus
An Introduction to PrometheusEvgeny Shmarnev
 
Intro to InfluxDB
Intro to InfluxDBIntro to InfluxDB
Intro to InfluxDBInfluxData
 
Monitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusMonitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusGrafana Labs
 
Stream processing using Kafka
Stream processing using KafkaStream processing using Kafka
Stream processing using KafkaKnoldus Inc.
 
VictoriaMetrics 2023 Roadmap
VictoriaMetrics 2023 RoadmapVictoriaMetrics 2023 Roadmap
VictoriaMetrics 2023 RoadmapVictoriaMetrics
 
Monitoring kubernetes with prometheus
Monitoring kubernetes with prometheusMonitoring kubernetes with prometheus
Monitoring kubernetes with prometheusBrice Fernandes
 
Getting Started: Intro to Telegraf - July 2021
Getting Started: Intro to Telegraf - July 2021Getting Started: Intro to Telegraf - July 2021
Getting Started: Intro to Telegraf - July 2021InfluxData
 
Timeseries - data visualization in Grafana
Timeseries - data visualization in GrafanaTimeseries - data visualization in Grafana
Timeseries - data visualization in GrafanaOCoderFest
 
Introduction to Redis
Introduction to RedisIntroduction to Redis
Introduction to RedisDvir Volk
 
Conference on Nagios: Reinhard Scheck on Cacti
Conference on Nagios: Reinhard Scheck on CactiConference on Nagios: Reinhard Scheck on Cacti
Conference on Nagios: Reinhard Scheck on CactiWürth Phoenix
 
A Survey of HBase Application Archetypes
A Survey of HBase Application ArchetypesA Survey of HBase Application Archetypes
A Survey of HBase Application ArchetypesHBaseCon
 
Stl meetup cloudera platform - january 2020
Stl meetup   cloudera platform  - january 2020Stl meetup   cloudera platform  - january 2020
Stl meetup cloudera platform - january 2020Adam Doyle
 

Tendances (20)

Introduction to Prometheus
Introduction to PrometheusIntroduction to Prometheus
Introduction to Prometheus
 
Monitoring with Prometheus
Monitoring with PrometheusMonitoring with Prometheus
Monitoring with Prometheus
 
Systems Monitoring with Prometheus (Devops Ireland April 2015)
Systems Monitoring with Prometheus (Devops Ireland April 2015)Systems Monitoring with Prometheus (Devops Ireland April 2015)
Systems Monitoring with Prometheus (Devops Ireland April 2015)
 
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)
 
An Introduction to Prometheus
An Introduction to PrometheusAn Introduction to Prometheus
An Introduction to Prometheus
 
Intro to InfluxDB
Intro to InfluxDBIntro to InfluxDB
Intro to InfluxDB
 
Monitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusMonitoring Kubernetes with Prometheus
Monitoring Kubernetes with Prometheus
 
Stream processing using Kafka
Stream processing using KafkaStream processing using Kafka
Stream processing using Kafka
 
VictoriaMetrics 2023 Roadmap
VictoriaMetrics 2023 RoadmapVictoriaMetrics 2023 Roadmap
VictoriaMetrics 2023 Roadmap
 
Grafana.pptx
Grafana.pptxGrafana.pptx
Grafana.pptx
 
Prometheus monitoring
Prometheus monitoringPrometheus monitoring
Prometheus monitoring
 
Monitoring kubernetes with prometheus
Monitoring kubernetes with prometheusMonitoring kubernetes with prometheus
Monitoring kubernetes with prometheus
 
Getting Started: Intro to Telegraf - July 2021
Getting Started: Intro to Telegraf - July 2021Getting Started: Intro to Telegraf - July 2021
Getting Started: Intro to Telegraf - July 2021
 
Timeseries - data visualization in Grafana
Timeseries - data visualization in GrafanaTimeseries - data visualization in Grafana
Timeseries - data visualization in Grafana
 
Introduction to Redis
Introduction to RedisIntroduction to Redis
Introduction to Redis
 
Conference on Nagios: Reinhard Scheck on Cacti
Conference on Nagios: Reinhard Scheck on CactiConference on Nagios: Reinhard Scheck on Cacti
Conference on Nagios: Reinhard Scheck on Cacti
 
Presto: SQL-on-anything
Presto: SQL-on-anythingPresto: SQL-on-anything
Presto: SQL-on-anything
 
A Survey of HBase Application Archetypes
A Survey of HBase Application ArchetypesA Survey of HBase Application Archetypes
A Survey of HBase Application Archetypes
 
Stl meetup cloudera platform - january 2020
Stl meetup   cloudera platform  - january 2020Stl meetup   cloudera platform  - january 2020
Stl meetup cloudera platform - january 2020
 
All about InfluxDB.
All about InfluxDB.All about InfluxDB.
All about InfluxDB.
 

En vedette

StatsD Workshop Monitorama 2013
StatsD Workshop Monitorama 2013StatsD Workshop Monitorama 2013
StatsD Workshop Monitorama 2013Daniel Schauenberg
 
Effective monitoring with StatsD
Effective monitoring with StatsDEffective monitoring with StatsD
Effective monitoring with StatsDDatadog
 
Statsd introduction
Statsd introductionStatsd introduction
Statsd introductionRick Chang
 
Statsd backends presentation
Statsd backends presentationStatsd backends presentation
Statsd backends presentationDraco2002
 
Scalable Monitoring & Alerting
Scalable Monitoring & AlertingScalable Monitoring & Alerting
Scalable Monitoring & AlertingFranklin Angulo
 
Metrics, Metrics Everywhere (but where the heck do you start?)
Metrics, Metrics Everywhere (but where the heck do you start?)Metrics, Metrics Everywhere (but where the heck do you start?)
Metrics, Metrics Everywhere (but where the heck do you start?)SOASTA
 
Metrics by coda hale : to know your app’ health
Metrics by coda hale : to know your app’ healthMetrics by coda hale : to know your app’ health
Metrics by coda hale : to know your app’ healthIzzet Mustafaiev
 
Gatling - Stress test tool
Gatling - Stress test toolGatling - Stress test tool
Gatling - Stress test toolKnoldus Inc.
 
Load testing with gatling
Load testing with gatlingLoad testing with gatling
Load testing with gatlingChris Birchall
 
Monitoring system with Grafana and StatsD
Monitoring system with Grafana and StatsDMonitoring system with Grafana and StatsD
Monitoring system with Grafana and StatsDArtur Prado
 

En vedette (12)

Graphite
GraphiteGraphite
Graphite
 
Go with the flow
Go with the flowGo with the flow
Go with the flow
 
StatsD Workshop Monitorama 2013
StatsD Workshop Monitorama 2013StatsD Workshop Monitorama 2013
StatsD Workshop Monitorama 2013
 
Effective monitoring with StatsD
Effective monitoring with StatsDEffective monitoring with StatsD
Effective monitoring with StatsD
 
Statsd introduction
Statsd introductionStatsd introduction
Statsd introduction
 
Statsd backends presentation
Statsd backends presentationStatsd backends presentation
Statsd backends presentation
 
Scalable Monitoring & Alerting
Scalable Monitoring & AlertingScalable Monitoring & Alerting
Scalable Monitoring & Alerting
 
Metrics, Metrics Everywhere (but where the heck do you start?)
Metrics, Metrics Everywhere (but where the heck do you start?)Metrics, Metrics Everywhere (but where the heck do you start?)
Metrics, Metrics Everywhere (but where the heck do you start?)
 
Metrics by coda hale : to know your app’ health
Metrics by coda hale : to know your app’ healthMetrics by coda hale : to know your app’ health
Metrics by coda hale : to know your app’ health
 
Gatling - Stress test tool
Gatling - Stress test toolGatling - Stress test tool
Gatling - Stress test tool
 
Load testing with gatling
Load testing with gatlingLoad testing with gatling
Load testing with gatling
 
Monitoring system with Grafana and StatsD
Monitoring system with Grafana and StatsDMonitoring system with Grafana and StatsD
Monitoring system with Grafana and StatsD
 

Similaire à Collecting metrics with Graphite and StatsD

Monitoring as Software Validation
Monitoring as Software ValidationMonitoring as Software Validation
Monitoring as Software ValidationBioDec
 
Python and trending_data_ops
Python and trending_data_opsPython and trending_data_ops
Python and trending_data_opschase pettet
 
Advanced data science algorithms applied to scalable stream processing by Dav...
Advanced data science algorithms applied to scalable stream processing by Dav...Advanced data science algorithms applied to scalable stream processing by Dav...
Advanced data science algorithms applied to scalable stream processing by Dav...Big Data Spain
 
Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...
Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...
Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...DataStax
 
StasD & Graphite - Measure anything, Measure Everything
StasD & Graphite - Measure anything, Measure EverythingStasD & Graphite - Measure anything, Measure Everything
StasD & Graphite - Measure anything, Measure EverythingAvi Revivo
 
Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"
Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"
Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"Fwdays
 
Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...
Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...
Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...Databricks
 
Amplitude wave architecture - Test
Amplitude wave architecture - TestAmplitude wave architecture - Test
Amplitude wave architecture - TestKiran Naiga
 
In-Memory Stream Processing with Hazelcast Jet @JEEConf
In-Memory Stream Processing with Hazelcast Jet @JEEConfIn-Memory Stream Processing with Hazelcast Jet @JEEConf
In-Memory Stream Processing with Hazelcast Jet @JEEConfNazarii Cherkas
 
Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv
Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv
Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv Amazon Web Services
 
Functional architectural patterns
Functional architectural patternsFunctional architectural patterns
Functional architectural patternsLars Albertsson
 
Cassandra Summit 2014: Cyanite — Better Graphite Storage with Apache Cassandra
Cassandra Summit 2014: Cyanite — Better Graphite Storage with Apache CassandraCassandra Summit 2014: Cyanite — Better Graphite Storage with Apache Cassandra
Cassandra Summit 2014: Cyanite — Better Graphite Storage with Apache CassandraDataStax Academy
 
Webinar: Cutting Time, Complexity and Cost from Data Science to Production
Webinar: Cutting Time, Complexity and Cost from Data Science to ProductionWebinar: Cutting Time, Complexity and Cost from Data Science to Production
Webinar: Cutting Time, Complexity and Cost from Data Science to Productioniguazio
 
Creating a scalable & cost efficient BI infrastructure for a startup in the A...
Creating a scalable & cost efficient BI infrastructure for a startup in the A...Creating a scalable & cost efficient BI infrastructure for a startup in the A...
Creating a scalable & cost efficient BI infrastructure for a startup in the A...vcrisan
 
Prometheus Everything, Observing Kubernetes in the Cloud
Prometheus Everything, Observing Kubernetes in the CloudPrometheus Everything, Observing Kubernetes in the Cloud
Prometheus Everything, Observing Kubernetes in the CloudSneha Inguva
 
Big Data Driven At Eway
Big Data Driven At Eway Big Data Driven At Eway
Big Data Driven At Eway Tu Pham
 
Tek12: Graphing real-time performance with Graphite
Tek12: Graphing real-time performance with GraphiteTek12: Graphing real-time performance with Graphite
Tek12: Graphing real-time performance with Graphitenanderoo
 
Google Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 DayGoogle Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 Dayprogrammermag
 
Cloud Computing ...changes everything
Cloud Computing ...changes everythingCloud Computing ...changes everything
Cloud Computing ...changes everythingLew Tucker
 

Similaire à Collecting metrics with Graphite and StatsD (20)

Monitoring as Software Validation
Monitoring as Software ValidationMonitoring as Software Validation
Monitoring as Software Validation
 
Python and trending_data_ops
Python and trending_data_opsPython and trending_data_ops
Python and trending_data_ops
 
Advanced data science algorithms applied to scalable stream processing by Dav...
Advanced data science algorithms applied to scalable stream processing by Dav...Advanced data science algorithms applied to scalable stream processing by Dav...
Advanced data science algorithms applied to scalable stream processing by Dav...
 
Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...
Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...
Lessons Learned on Java Tuning for Our Cassandra Clusters (Carlos Monroy, Kne...
 
StasD & Graphite - Measure anything, Measure Everything
StasD & Graphite - Measure anything, Measure EverythingStasD & Graphite - Measure anything, Measure Everything
StasD & Graphite - Measure anything, Measure Everything
 
Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"
Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"
Александр Махомет "Beyond the code или как мониторить ваш PHP сайт"
 
Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...
Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...
Large Scale Feature Aggregation Using Apache Spark with Pulkit Bhanot and Ami...
 
Amplitude wave architecture - Test
Amplitude wave architecture - TestAmplitude wave architecture - Test
Amplitude wave architecture - Test
 
In-Memory Stream Processing with Hazelcast Jet @JEEConf
In-Memory Stream Processing with Hazelcast Jet @JEEConfIn-Memory Stream Processing with Hazelcast Jet @JEEConf
In-Memory Stream Processing with Hazelcast Jet @JEEConf
 
Enterprise Data Lakes
Enterprise Data LakesEnterprise Data Lakes
Enterprise Data Lakes
 
Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv
Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv
Streaming data analytics (Kinesis, EMR/Spark) - Pop-up Loft Tel Aviv
 
Functional architectural patterns
Functional architectural patternsFunctional architectural patterns
Functional architectural patterns
 
Cassandra Summit 2014: Cyanite — Better Graphite Storage with Apache Cassandra
Cassandra Summit 2014: Cyanite — Better Graphite Storage with Apache CassandraCassandra Summit 2014: Cyanite — Better Graphite Storage with Apache Cassandra
Cassandra Summit 2014: Cyanite — Better Graphite Storage with Apache Cassandra
 
Webinar: Cutting Time, Complexity and Cost from Data Science to Production
Webinar: Cutting Time, Complexity and Cost from Data Science to ProductionWebinar: Cutting Time, Complexity and Cost from Data Science to Production
Webinar: Cutting Time, Complexity and Cost from Data Science to Production
 
Creating a scalable & cost efficient BI infrastructure for a startup in the A...
Creating a scalable & cost efficient BI infrastructure for a startup in the A...Creating a scalable & cost efficient BI infrastructure for a startup in the A...
Creating a scalable & cost efficient BI infrastructure for a startup in the A...
 
Prometheus Everything, Observing Kubernetes in the Cloud
Prometheus Everything, Observing Kubernetes in the CloudPrometheus Everything, Observing Kubernetes in the Cloud
Prometheus Everything, Observing Kubernetes in the Cloud
 
Big Data Driven At Eway
Big Data Driven At Eway Big Data Driven At Eway
Big Data Driven At Eway
 
Tek12: Graphing real-time performance with Graphite
Tek12: Graphing real-time performance with GraphiteTek12: Graphing real-time performance with Graphite
Tek12: Graphing real-time performance with Graphite
 
Google Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 DayGoogle Cloud Computing on Google Developer 2008 Day
Google Cloud Computing on Google Developer 2008 Day
 
Cloud Computing ...changes everything
Cloud Computing ...changes everythingCloud Computing ...changes everything
Cloud Computing ...changes everything
 

Plus de itnig

Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...
Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...
Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...itnig
 
Web Scraping for Non Programmers
Web Scraping for Non ProgrammersWeb Scraping for Non Programmers
Web Scraping for Non Programmersitnig
 
Hands-On Prototyping Without Code
Hands-On Prototyping Without CodeHands-On Prototyping Without Code
Hands-On Prototyping Without Codeitnig
 
Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...
Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...
Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...itnig
 
Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...
Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...
Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...itnig
 
Data Tools cosystem_for_non_programmers
Data Tools cosystem_for_non_programmersData Tools cosystem_for_non_programmers
Data Tools cosystem_for_non_programmersitnig
 
The Black Magic of Ruby Metaprogramming
The Black Magic of Ruby MetaprogrammingThe Black Magic of Ruby Metaprogramming
The Black Magic of Ruby Metaprogrammingitnig
 
Futurology For Entrepreneurs: 7 Ways To Spot The Opportunities Of Tomorrow
Futurology For Entrepreneurs: 7 Ways To Spot The Opportunities Of TomorrowFuturology For Entrepreneurs: 7 Ways To Spot The Opportunities Of Tomorrow
Futurology For Entrepreneurs: 7 Ways To Spot The Opportunities Of Tomorrowitnig
 
Visualizing large datasets (BIG DATA itnig friday)
Visualizing large datasets (BIG DATA itnig friday)Visualizing large datasets (BIG DATA itnig friday)
Visualizing large datasets (BIG DATA itnig friday)itnig
 
Make your own Open Source transition with CocoaPods
Make your own Open Source transition with CocoaPodsMake your own Open Source transition with CocoaPods
Make your own Open Source transition with CocoaPodsitnig
 
"El boom del Consumo Colaborativo" by Albert Cañigueral
"El boom del Consumo Colaborativo" by Albert Cañigueral"El boom del Consumo Colaborativo" by Albert Cañigueral
"El boom del Consumo Colaborativo" by Albert Cañigueralitnig
 
Control Your Life - The Startup Way
Control Your Life - The Startup WayControl Your Life - The Startup Way
Control Your Life - The Startup Wayitnig
 
Analítica Ágil - De la Sobrecarga a la Evidencia de los Datos
Analítica Ágil - De la Sobrecarga a la Evidencia de los DatosAnalítica Ágil - De la Sobrecarga a la Evidencia de los Datos
Analítica Ágil - De la Sobrecarga a la Evidencia de los Datositnig
 
Ser público en internet lo es todo.
Ser público en internet lo es todo.Ser público en internet lo es todo.
Ser público en internet lo es todo.itnig
 
Performance marketingonline enterategratis_
Performance marketingonline enterategratis_Performance marketingonline enterategratis_
Performance marketingonline enterategratis_itnig
 
SEO para ecommerce by Alfonso Moure
SEO para ecommerce by Alfonso MoureSEO para ecommerce by Alfonso Moure
SEO para ecommerce by Alfonso Moureitnig
 
Hablar en Público by Marion Chevalier
Hablar en Público by Marion ChevalierHablar en Público by Marion Chevalier
Hablar en Público by Marion Chevalieritnig
 
La burbuja publicitaria
La burbuja publicitariaLa burbuja publicitaria
La burbuja publicitariaitnig
 
Analisis de las empresas del Ibex35
Analisis de las empresas del Ibex35Analisis de las empresas del Ibex35
Analisis de las empresas del Ibex35itnig
 
One graph to rule them all - Facebook
One graph to rule them all - FacebookOne graph to rule them all - Facebook
One graph to rule them all - Facebookitnig
 

Plus de itnig (20)

Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...
Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...
Presentation of the project "Startups Made in Spain" · On Friday, January 9 a...
 
Web Scraping for Non Programmers
Web Scraping for Non ProgrammersWeb Scraping for Non Programmers
Web Scraping for Non Programmers
 
Hands-On Prototyping Without Code
Hands-On Prototyping Without CodeHands-On Prototyping Without Code
Hands-On Prototyping Without Code
 
Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...
Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...
Essentials Every Non-Technical Person Need To Know To Build The Best Tech-Tea...
 
Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...
Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...
Die Another Day: Scaling from 0 to 4 million daily requests as a lone develop...
 
Data Tools cosystem_for_non_programmers
Data Tools cosystem_for_non_programmersData Tools cosystem_for_non_programmers
Data Tools cosystem_for_non_programmers
 
The Black Magic of Ruby Metaprogramming
The Black Magic of Ruby MetaprogrammingThe Black Magic of Ruby Metaprogramming
The Black Magic of Ruby Metaprogramming
 
Futurology For Entrepreneurs: 7 Ways To Spot The Opportunities Of Tomorrow
Futurology For Entrepreneurs: 7 Ways To Spot The Opportunities Of TomorrowFuturology For Entrepreneurs: 7 Ways To Spot The Opportunities Of Tomorrow
Futurology For Entrepreneurs: 7 Ways To Spot The Opportunities Of Tomorrow
 
Visualizing large datasets (BIG DATA itnig friday)
Visualizing large datasets (BIG DATA itnig friday)Visualizing large datasets (BIG DATA itnig friday)
Visualizing large datasets (BIG DATA itnig friday)
 
Make your own Open Source transition with CocoaPods
Make your own Open Source transition with CocoaPodsMake your own Open Source transition with CocoaPods
Make your own Open Source transition with CocoaPods
 
"El boom del Consumo Colaborativo" by Albert Cañigueral
"El boom del Consumo Colaborativo" by Albert Cañigueral"El boom del Consumo Colaborativo" by Albert Cañigueral
"El boom del Consumo Colaborativo" by Albert Cañigueral
 
Control Your Life - The Startup Way
Control Your Life - The Startup WayControl Your Life - The Startup Way
Control Your Life - The Startup Way
 
Analítica Ágil - De la Sobrecarga a la Evidencia de los Datos
Analítica Ágil - De la Sobrecarga a la Evidencia de los DatosAnalítica Ágil - De la Sobrecarga a la Evidencia de los Datos
Analítica Ágil - De la Sobrecarga a la Evidencia de los Datos
 
Ser público en internet lo es todo.
Ser público en internet lo es todo.Ser público en internet lo es todo.
Ser público en internet lo es todo.
 
Performance marketingonline enterategratis_
Performance marketingonline enterategratis_Performance marketingonline enterategratis_
Performance marketingonline enterategratis_
 
SEO para ecommerce by Alfonso Moure
SEO para ecommerce by Alfonso MoureSEO para ecommerce by Alfonso Moure
SEO para ecommerce by Alfonso Moure
 
Hablar en Público by Marion Chevalier
Hablar en Público by Marion ChevalierHablar en Público by Marion Chevalier
Hablar en Público by Marion Chevalier
 
La burbuja publicitaria
La burbuja publicitariaLa burbuja publicitaria
La burbuja publicitaria
 
Analisis de las empresas del Ibex35
Analisis de las empresas del Ibex35Analisis de las empresas del Ibex35
Analisis de las empresas del Ibex35
 
One graph to rule them all - Facebook
One graph to rule them all - FacebookOne graph to rule them all - Facebook
One graph to rule them all - Facebook
 

Dernier

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfhans926745
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 

Dernier (20)

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 

Collecting metrics with Graphite and StatsD

  • 1.
  • 2. Collecting metrics with Graphite and StatsD Víctor Martínez @knoopx http://github.com/knoopx http://knoopx.net
  • 4. What is Graphite? An all-in-one solution for storing and visualizing realtime time-series data in an efficient manner. Key features: Efficient storage and ultra-fast retrieval. http://graphite.wikidot.com/
  • 5. Graphite Architecture Graphite Web The frontend of Graphite. It provides a dashboard for retrieval and visualization of our metrics and a powerful plotting API. Carbon The core of Graphite. It consists of set of three processes that take care of receiving incoming data, aggregating it and persisting it to disk. Whisper The current (stable) data persistence storage; an efficient time-series based database. * There's a new persistence layer called Ceres in the works
  • 6. Feeding in your data PORT=2003 SERVER=graphite.your.org echo "stats.app.logins.count 1 `date +%s`" | nc ${SERVER} ${PORT}; PORT=2003 SERVER=graphite.your.org echo "stats.app.logins.count 1 `date +%s`" | nc ${SERVER} ${PORT}; PORT=2003 SERVER=graphite.your.org echo "stats.app.logins.count 1 `date +%s`" | nc ${SERVER} ${PORT}; schema.application_name.namespace.metric_name.metric_type Value Name Timestamp
  • 7. Understanding how Carbon works storage-schemas.conf Allows you to define how your data should be persisted (retention rules) and in which order (priority). storage-aggregation.conf Allows you to define how your metrics should be aggregated. Key configuration files
  • 8. Understanding how Carbon works storage-schemas.conf What does retention mean? In a timespan of X time, in how much granularity I want to store my data
  • 9. Understanding how Carbon works storage-schemas.conf ● For a timespan of 6 hours I want to store my data in intervals of 10 seconds. ● For a timespan of 7 days I want to store my data in intervals of 1 minute. ● For a timespan of 1 year I want to store my data in intervals of 1 hour. ● For a timespan of 5 year I want to store my data in intervals of 24 hours.
  • 10. Understanding how Carbon works storage-schemas.conf
  • 11. Understanding how Carbon works storage-aggregation.conf Some examples: stats.app.users.logins.count stats.app.emails.sent.count stats.app.orders.amount.max stats.app.orders.amount.min stats.app.response.time
  • 12. Understanding how Carbon works storage-aggregation.conf
  • 13. Understanding how Carbon works Carbon limitations What happens if I send two metrics at the same timespan (1h)? 1 new user – 6 minutes ago 2 new users – 5 minutes ago
  • 14. Understanding how Carbon works Carbon limitations Carbon discards everything but the last one 2 users
  • 15. Understanding how Carbon works Carbon limitations ● Increase schema retention: 1s:12h,[...] and never, ever, push metrics older than 12 hours/push more than once per second ● Pre-aggregate your data before pushing ● Use StatsD Possible Solutions:
  • 16. Understanding how Carbon works Pre-aggregate your data https://gist.github.com/knoopx/4738209
  • 17. Understanding how Carbon works Use StatsD What is StatdD? A network daemon that runs on the Node.js platform and listens for statistics, like counters and timers, sent over UDP and sends aggregates to one or more pluggable backend services (e.g., Graphite). Key features: Aggregates the data for us, fire and forget communication protocol (UDP) https://github.com/etsy/statsd/
  • 18. Understanding how Carbon works https://github.com/Shopify/statsd-instrument StatsD.increment('revenue', 23.99) StatsD.measure('worker.time') do Worker.perform(value) end StatsD Instrument Gem Important: Carefully read StatsD documentation and ensure that your Carbon configuration explicitly matches StatsD naming conventions
  • 19. Visualizing your metrics Using the Graphite dashboard Common functions: ● summarize ● timeShift ● keepLastValue ● integral ● drawAsInfinite ● sumSeries ● alias ● aliasByNode Full Documentation: http://graphite.readthedocs. org/en/1.0/functions.html
  • 20. Visualizing your metrics Using the Graphite dashboard Time-shifting and aliasing: alias(timeShift(camaloon.sidekiq.workers.success.count,"24h"),"Yesterday") alias(camaloon.sidekiq.workers.success.count,"Today")
  • 21. Visualizing your metrics Using the Graphite dashboard Summarizing data: summarize(camaloon.sidekiq.workers.success.count,"1h") 1h
  • 22. Visualizing your metrics Using the Graphite dashboard Aliasing and combining series: aliasByNode(camaloon.sidekiq.workers.*.count, 3)
  • 23. Visualizing your metrics Tasseo https://github.com/obfuscurity/tasseo Cubism.js https://github.com/square/cubism
  • 24. Visualizing your metrics Graphene https://github.com/jondot/graphene
  • 25. Visualizing your metrics Your own solution /render/?target=camaloon.users.count&format=json We internally use Highchart Highstock