Sander Aernouts
Sep 5, 2018 · 1 min read

I haven’t tried it, but I think you can mimic at the metrics collection part of Prometheus by using Log Analytics. You should at least be able to gather metrics about your nodes, pods and containers using https://docs.microsoft.com/en-us/azure/monitoring/monitoring-container-health.

From within your application you could try sending custom metrics back to log analytics using HTTP data collector API (https://docs.microsoft.com/en-us/azure/log-analytics/log-analytics-data-collector-api). Or you could look at using Application Insights for this purpose.

But as far as I know there is no Kubernetes “native” way to do this (Custom Resource Definitions). With the Prometheus Operator installed in your cluster you can configure Prometheus using resource definitions just like you would for deploying a pod or a service or anything else.

Another difference would be that Prometheus “pulls” the metrics from an endpoints on your application whereas with Log Analytics your application needs to know where to send (“push”) the metrics (HTTP data collector API).

But with Log Analytics and Application insights you should be able to gather metrics from both your cluster infrastructure and your application.