O slideshow foi denunciado.
Utilizamos seu perfil e dados de atividades no LinkedIn para personalizar e exibir anúncios mais relevantes. Altere suas preferências de anúncios quando desejar.

Collecting metrics with Prometheus and VictoriaMetrics - Aliaksandr Valialkin (RUS) | Ruby Meditation 26

42 visualizações

Publicada em

Speech of Aliaksandr Valialkin, Founder VictoriaMetrics, at Ruby Meditation #26 Kyiv 16.02.2019
Next conference - http://www.rubymeditation.com/

Prometheus is a popular solution for metrics' collection and alerting. But it isn't suited for storing historical data. Let's see how VictoriaMetrics resolves this issue.

Announcements and conference materials https://www.fb.me/RubyMeditation
News https://twitter.com/RubyMeditation
Photos https://www.instagram.com/RubyMeditation
The stream of Ruby conferences (not just ours) https://t.me/RubyMeditation

Publicada em: Tecnologia
  • Seja o primeiro a comentar

  • Seja a primeira pessoa a gostar disto

Collecting metrics with Prometheus and VictoriaMetrics - Aliaksandr Valialkin (RUS) | Ruby Meditation 26

  1. 1. Collecting metrics with Prometheus and VictoriaMetric Aliaksandr Valialkin, VictoriaMetrics
  2. 2. Let me introduce myself ● VictoriaMetrics founder and core developer ● Fasthttp creator ● Fond of performance optimizations
  3. 3. What is Prometheus? ● The most popular monitoring system ● Metrics’ collector ● Time Series DB ● Rules evaluator and alerter
  4. 4. What Prometheus can do? ● Collecting metrics from pre-configured targets ● Storing metrics in the local and remote DBs ● Executing queries against metrics stored in the DB ● Sending alerts on pre-configured rules ● Helping to build nice dashboards in Grafana
  5. 5. Ruby + Prometheus ● https://github.com/reinh/statsd + https://github.com/prometheus/statsd_exporter ● https://github.com/prometheus/client_ruby - hard to use properly due to support pre-fork (unicorn) servers issue
  6. 6. https://github.com/reinh/statsd usage # Set up a global Statsd client for a server on localhost:9125 $statsd = Statsd.new 'localhost', 9125 # Send some stats $statsd.increment 'garets' $statsd.timing 'glork', 320 $statsd.gauge 'bork', 100 # Use {#time} to time the execution of a block $statsd.time('account.activate') { @account.activate! } # Create a namespaced statsd client and increment 'account.activate' statsd = Statsd.new('localhost').tap{|sd| sd.namespace = 'account'} statsd.increment 'activate'
  7. 7. Local DB issues in Prometheus ● Doesn’t scale outside the node ● Has limited size and retention (15 days)
  8. 8. Remote DB to rescue ● Remote DB may transparently scale to many nodes ● Remote DB may deal better with big retentions ● Remote DB may collect and query data from multiple Prometheus instances ● Remote storages for Prometheus - https://prometheus.io/docs/operating/integrations/#remote-endpoints- and-storage
  9. 9. What is VictoriaMetrics? ● Long-term remote storage for Prometheus ● Single-node version is available at https://github.com/VictoriaMetrics/VictoriaMetrics/wiki/Single-server-VictoriaMetrics ● SaaS is in progress at https://victoriametrics.com ● There is SaaS playground at https://play.victoriametrics.com/signIn
  10. 10. VictoriaMetrics features ● Fast and cost-effective - see articles at https://medium.com/@valyala ● Easy to operate - just a single executable without dependencies ● Supports PromQL - native query language for Prometheus ● Accepts metrics in InfluxDB and Graphite formats
  11. 11. Questions?

×