Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Short answer: it's configurable, but the default behavior is the one you want (the cache is dropped between flush cycles).</p> <p>Long answer: statsd doesn't actually report to graphite. It can however load a plugin that will do so (and it's delivered with such plugin).</p> <p>The important thing to understand is that while plugins can report success or failure to init, the have no callback or other feedback option for flush events. The graphite plugin registers for 2 events, status and flush (<a href="https://github.com/etsy/statsd/blob/master/backends/graphite.js" rel="nofollow">https://github.com/etsy/statsd/blob/master/backends/graphite.js</a> line 230), out of which flush is the only event that report metrics.</p> <p>The graphite plugin register for the flush event. During a flush event, the node EventEmitter, will call all registered plugins, with A COPY of cached stats data. A different copy is sent to every plugin with no guaranty of order. You can see that happening if you look at <a href="https://github.com/etsy/statsd/blob/master/stats.js" rel="nofollow">https://github.com/etsy/statsd/blob/master/stats.js</a> line 32, where you'll see metrics_hash being created and populated, then later used to emit the flush event (line 122).</p> <p>The cache itself is dropped immediately after the the copy is populated (lines 77-120). As you can see in the code, you can change this default behavior, for a specific metric type (times, gauges, counters, sets) by adding an entry to the config file. To keep the counter cache for example, you should add deleteCounters = true to your config. Notice that this config will always keep the cached metrics, regardless of the success or failure of any plugin. </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload