etsy/statsd-jvm-profiler

Missing hostname in metric

Closed this issue · 2 comments

wnds commented

Hostname's are missing in metrics being generated. If plugin is deployed on multiple jvm's across hosts and data is fed into same statsd instance then metrics are not useful due to overlap.

@mail2vks: you can use the prefix global option to include the hostname if that's what you want.
It would be close to impossible to foresee all potential requirements from different people/organizations regarding how they want their metrics generated. You asked for hostname. Someone might ask for hostname + datacenter. Some might ask for a Docker container name + hostname + datacenter. You get the idea...

wnds commented

@AlejandroRivera Agree with you. I added changes to pass hostname in prefix by resolving hostname from env. variables like prefix=server-$(hostname)