Closed greg-mcnamara closed 4 days ago
The issue here is that the functionality to update the "discovery" state has been removed in 2.9 with the consolidation of all functionalities of the OPC Discovery module into the OPC Publisher. The code was left to aid in porting, but it is misleading as you would only see that it is unsupported by looking at the web api server logs.
We did not carry this capability forward, because a) it was not desired to have constantly scanning capability, and b) originally the discovery state was maintained as a desired property in the IoT Device Twin. However, you can use the programmatic "Discover_V2" API to kick off a one-time discovery run, which takes the discovery mode and optional configuration as arguments.
We will remove the misleading documentation and API from 2.9.10. Sorry for the confusion.
Describe the bug I have deployed the latest IIoT platform services and Simulation components on Azure. I can connect to the API via Postman, and I can see the gateways via GET registry/v2/gateways, but when I query endpoints there are none listed. Should I see endpoints already discovered in the simulation deployment, or is there another step I need to do?
I wondered if the problem was related to discovery configuration. I noticed that GET registry/v2/discovery returns a single discoverer with "discovery" set to "Off". I have tried to enable discovery via the API as per the instructions but when I check again it's still set to "Off".
To Reproduce Steps to reproduce the behavior:
Install Industrial-IoT platform with services and simulation.
Connect to the web API and query endpoints, none found.
Query the simulated Linux gateway and receive the following response:
Try to update the discoverer with POST/PATCH registry/v2/discovery/[discovererId] methods. Updates accepted ok by the API.
Check discoverer, "discovery" still "Off".
Expected behavior Discovery on the simulated gateway would be on by default, and endpoints on the PLC simulation would be discoverable via the API.