#Is there a way to log which API calls Harvest is making?

1 messages · Page 1 of 1 (latest)

tulip gyro
#

I find the "Explore" function in Harvest very useful to identify which ONTAP metrics are being queried. Is there a way to log which API calls are actually being made by Harvest?

For example, I'm interested in Fabric Pool statistics. There's a latency counter in Harvest called fabricpool_cloud_bin_op_latency_average, which in turn hits the ONTAP REST API endpoint /api/cluster/counter/tables/wafl_comp_aggr_vol_bin. As far as I can tell, that endpoint must be queried with one volume name at a time, but it looks like Harvest finds a way to query all volumes at once.

Specifically, this is the metrics query in Harvest: topk(5, fabricpool_cloud_bin_op_latency_average{datacenter=~"us-east-1",cluster=~"FsxId01234567890abcdef",svm=~"(svm0|svm1|svm2|vs1)",volume=~"()", metric="GET"})

If I've selected 5 volumes in Harvest, is that making one API call? Or 5?

hexed dome
#

@tulip gyro /api/cluster/counter/tables/wafl_comp_aggr_vol_bin/rows?fields=* will provide all records from ONTAP. Harvest will only make 1 call to collect this data in 1 poll. Harvest data collection is independent of Grafana or prometheus query.

tulip gyro
#

Rahul, you are a gentleman and a scholar 🥹

hexed dome
#

you are welcome @tulip gyro !

tulip gyro
#

are there any other tips & tricks you can think of to query APIs? I am pretty new to REST APIs.. and curl..

hexed dome
tulip gyro
#

I think just general suggestions: e.g. "to query all volumes at once, do fields=*" like you gave me already

hexed dome