How to graphic a Division between two selected metrics

Hi,

Starting from MetricBeats metrics with the ElasticSearch Module. I want to graphic on Kibana the Search Latency. I know that the necessary metrics are node_stats.indices.search.query_time_in_millis and node_stats.indices.search.query_total, but because both are cumulative, I have to apply the Derivate of each one.
Once this is calculated, I have to do the division between them for obtaining the Latency, but I don't know how to do this on Kibana.

Is this possible or am I trying to do something impossible?

Metrics:
image
image

Buckets:
image

Current Graphics: (with both metrics separately)

Thanks in advance

Hi @fchantada
unfortunately it's not possible to do that using the Visualize line chart, but you can do that with TSVB that allows you to apply the derivative and any other Math between series.
Please also check this link that maybe useful https://www.elastic.co/blog/visualizing-observability-with-kibana-event-rates-and-rate-of-change-in-tsvb

1 Like

Hi @markov00 , thank you very much for your reply.
Finally, I've resolved it using Timelion. I leave the example here:

.es(index=".monitoring-es-7-mb*",q=cluster_uuid:xxx,
timefield='timestamp', metric='max:node_stats.indices.search.query_time_in_millis').derivative().divide(.es(index=".monitoring-es-7-mb*",q=cluster_uuid:xxx,
timefield='timestamp',
metric='max:node_stats.indices.search.query_total').derivative())
.legend(columns=1, position=s)
.label("Search")

1 Like

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