Search code examples
apache-sparkgraphitegraphite-carbon

Graphite, collect metrics with similar names from different hosts


I've installed Graphite+Carbon to collect metrics from several hosts. These hosts send Apache Spark and Java metrics. I can't distinguish metrics from different hosts on Graphite side. What should be the right approach? I want to group metrics by host.

Graphite

"Master" is located on remote host, "workers" are located on three remote hosts and I can't distinguish incoming numbers. Don't understand what is the right way to add host determinant into metric.


Solution

  • Graphite has the notion of namespaces. e.g. host.app.metric.dimension If you don't send your metrics in this way you have no way of distinguishing them from one another.

    Depending on your library there should be a way to prefix the sent metrics with some kind of identifier. I recommend some unique internal identifier and then going on from it.