Created 12-28-2017 07:36 AM
I created new Reporting task in Nifi with process group ID to monitor specific Nifi process group.
I can see data from this Reporting task in Grafana, but I am unable to get this metric via some API interface to pass it to the Zabbix dashboard for alerting purposes. I have tried the following:
$ curl -u xxxx:******** -H 'X-Requested-By: ambari' http://myhost:6188/ws/v1/timeline/metrics?metricNames=nifi.BytesWrittenLast5Minutes.0373e5ac-51dc-33...
[1] 30260
$ {"metrics":[]}
[1]+ Done curl -u xxxx:******** -H 'X-Requested-By: ambari' http://myhost:6188/ws/v1/timeline/metrics?metricNames=nifi.BytesWrittenLast5Minutes.0373e5ac-51dc-33...
$
and
$ curl -u xxxx:******** -H 'X-Requested-By: ambari' http://myhost:6188/ws/v1/timeline/metrics?metricNames=AMBARI_METRICS.nifi.BytesWrittenLast5Minutes.0...
[1] 1866
$ {"metrics":[]}
[1]+ Done curl -u xxxx:******** -H 'X-Requested-By: ambari' http://myhost:6188/ws/v1/timeline/metrics?metricNames=AMBARI_METRICS.nifi.BytesWrittenLast5Minutes.0...
$
But either of these are correct responses.
What I am missing or doing wrong?
Created 12-28-2017 07:40 AM
Ambari version is 2.5.2.0, HDP version is 2.6.1.0 and Nifi version is 1.2.0 (I have HDF integrated to the Ambari).
Created 12-28-2017 05:03 PM
you can add a reporting task for zabbix
https://github.com/dbist/workshops/tree/master/nifi/templates/zabbix
https://pierrevillard.com/2017/05/11/monitoring-nifi-introduction/
Created 12-29-2017 06:25 AM
Thank you Timothy especially for the Zabbix example!
Unfortunately I am looking for different kind of solution here.
So my question remains. How to get Ambari metrics values via curl?