Your data. Anywhere you go.

New Relic for iOS or Android


Download on the App Store    Android App on Google play


New Relic Insights App for iOS


Download on the App Store


Learn more

Close icon

Monitoring Custom Golang Application Metrics


#1

I’ve seen posts on here about monitoring application metrics, by collecting data from Prometheus or StatsD. That’d be great but I understand those could be much bigger scopes.

I’m pondering whether it’d be possible for the Kubernetes agent to introduce something like a K8sApplicationMetricSample that was populated from Golang EXPVAR metrics.

metrics. The standard way of annotating pods that support prometheus metrics is something like:

                prometheus.io/path: /metrics
                prometheus.io/port: 8080
                prometheus.io/scrape: true

I’m wondering if we could follow this model and introduce something like:

                newrelic.com/scrape/golang/path: /debug/vars
                newrelic.com/scrape/golang/port: 8080
                newrelic.com/scrape/golang/enabled: true

I’m open to any way to get custom application metrics out and would be happy to work on a PR to the agent if there’s a Github repo available to do this work?


#2

Hi @brandon.cole,

This is certainly a great idea! I can log a feature request on this. If you have any additional information to convey, please let me know.

We do have a custom integration SDK that may work for you. This works in conjunction with the Infra agent:

https://docs.newrelic.com/docs/integrations/integrations-sdk/getting-started/introduction-infrastructure-integrations-sdk

Alternatively, we do have a Insert API that will let you send JSON data directly to Insights. More info here:

https://docs.newrelic.com/docs/insights/insights-data-sources/custom-data/send-custom-events-event-api

Our Kubernetes integration isn’t on our public github currently.