Device list issue on TSDN CFP M2 release.: For device list we got recommendation to use the same path "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map/lsa-utils:device/lsa-utils:name" that works in LSA or non-LSA setup. But using this path we have issue in the JSON RPC query API to make the filter functionality work. And also the RFS nodes are returned in the device list.
Hi Demeke,Please provide the JSON RPC query you were using earlier and the current query.Regards,NishadHi Nishad, This is the current query request,{"params": {"path": "/ncs:devices/device","selection": ["name"],"result_as": "string","xpath_expr": "device[contains(name,"-5")]","context_node": "/ncs:devices","initial_offset": 1,"chunk_size": 50,"th": 6},"jsonrpc": "2.0","id": 91,"method": "query"}And currently on the above request the issue is replacing the path parameter with the recommended path '/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map/lsa-utils:device/lsa-utils:name'. Please note listing is fine the issue on filtering.Thanks,Demeke.Hi Demeke,We can use the following queries to get the remote / local nodes : To get the devices on remote node : "xpath_expr": "device[ boolean(remote-node) ]"} }', "path": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map/lsa-utils:device", "context_node": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map",To get the devices on local node : "xpath_expr": "device[ boolean(local) ]"} }', "path": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map/lsa-utils:device", "context_node": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map",Please find the attached file for examples.Regards,NishadHi Nishad,We want to filter devices by name and your suggestion below is not helping our usecase.However using the path and context node params from you request, "path": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map/lsa-utils:device","context_node": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map" is actually working for listing and filtering. The following is how we constructed the API request and please confirm the usage, {"params":{"path":"/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map/lsa-utils:device","selection":,"result_as":"string","xpath_expr":"device","context_node":"/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map","initial_offset":1,"chunk_size":50,"th":1},"jsonrpc":"2.0","id":47,"method":"query"} And also I still see the issue in the device list sending the RFS nodes in the device list.Please refer the screenshot that shows the issue in NSO UI.Thanks,Demeke.Hi Demeke,The query you mentioned doesnot filter the RFS nodes.For example , below expression needs to be changed."xpath_expr":"device" --<del>> changed in case of </del>--> "xpath_expr":"device"Thanks,NishadHi Nishad, It seems like we need to have a quick meeting to close all the gaps.I will schedule a meeting for tomorrow please feel free to forward for anyone appropriate. Thanks,Demeke.Hi,Had a webex meeting with the submitter and agreed to provide a unified query for both LSA and non-LSA case.Provided the same over email."xpath_expr": "device","path": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map/lsa-utils:device","context_node": "/ncs:devices/lsa-utils:lsa/lsa-utils:dispatch-map"Thanks,NishadHi ,Provided the query parameters over the email. Submitter confirmed that the query works fine with the provided input.Email communication attached.Regards,Nishad