02 Jun 2021 01:52 PM - last edited on 03 Oct 2022 11:04 AM by Ana_Kuzmenchuk
I am using the V2 metrics API to retrieve common system metrics, in this case swap availability and usage.
type(HOST),tag(MyApplication:MyTag)
builtin:host.mem.swap.(used,avail):names:merge(1)
I need the common ""dt.entity.host.name" name and not the cryptic one. It works fine, but if I peek in the warnings, I see this:
warnings": [
"Usage of index \"1\" is deprecated, please consider converting the query to use the dimension key \"dt.entity.host\" instead"
How do I change my metrics selector to the newer format?
Any help is greatly appreciated.
Lou
Solved! Go to Solution.
02 Jun 2021 02:02 PM
Wait, I think I see it. It is as easy as this? I guess I really should have read the error.
builtin:host.cpu.usage:names:merge(dt.entity.host)
Thanks,
Lou