# Metricbeat - Haproxy stats delta for (IN bytes and OUT bytes)

**URL:** <https://discuss.elastic.co/t/metricbeat-haproxy-stats-delta-for-in-bytes-and-out-bytes/197679>\
**Category:** Beats\
**Tags:** metricbeat\
**Created:** [September 2, 2019, 11:26am UTC](https://discuss.elastic.co/t/metricbeat-haproxy-stats-delta-for-in-bytes-and-out-bytes/197679 "2019-09-02T11:26:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![praveenkumar.2608](https://avatars.discourse-cdn.com/v4/letter/p/e79b87/32.png) [@praveenkumar.2608](https://discuss.elastic.co/u/praveenkumar.2608)\
**Post date:** [September 2, 2019, 11:26am UTC](https://discuss.elastic.co/t/metricbeat-haproxy-stats-delta-for-in-bytes-and-out-bytes/197679/1 "2019-09-02T11:26:36Z")

</div>

Hi,

I am using metricbeat to collect haproxy stats. It seems metricbeat does not calculate delta for cumulative fields like (haproxy.stats.in.bytes and haproxy.stats.out.bytes). Is there any way to calculate the delta value. I have tried writing logstash filter to caculate delta but I am unable to make it working properly.

The reason why I need delta value is to find out the total volume of upload and download per day, week and month.

Example:-

Daily graph showing total sum of volume of upload and download when we choose daily in kibana. same for Mothly and weekly.

---

<div class="post-metadata">

**Author:** ![Mario\_Castro](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mario_castro/32/35107_2.png) [@Mario\_Castro](https://discuss.elastic.co/u/Mario_Castro)\
**Post date:** [September 3, 2019, 1:23pm UTC](https://discuss.elastic.co/t/metricbeat-haproxy-stats-delta-for-in-bytes-and-out-bytes/197679/2 "2019-09-03T13:23:57Z")

</div>

Hi @praveenkumar.2608 🙂

This is usually done in a Elasticsearch query by using buckets. This is easy to achieve if you create your own visualization in Kibana too.

Regards!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [October 1, 2019, 1:24pm UTC](https://discuss.elastic.co/t/metricbeat-haproxy-stats-delta-for-in-bytes-and-out-bytes/197679/3 "2019-10-01T13:24:04Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
