Skip to main content

list_opcda_servers

Function list_opcda_servers 

Source
pub async fn list_opcda_servers(bridge_host: &str) -> DriverResult<Vec<String>>
Expand description

Lists the OPC DA servers registered on the opcda-bridge gateway’s own host at bridge_host (e.g. "localhost:7600").

A standalone free function rather than a Driver method or an OpcDaDriver associated function: server discovery is a pre-connection operation — it needs only a bridge host, not the OPC DA server ProgID that OpcDaDriver::connect requires and that discovery exists to help a caller find in the first place. Connects for the one call and drops the connection immediately afterward; unlike OpcDaDriver, there is no ongoing session to hold open here.

Note: opcda_bridge::Client::list_servers always sends host: "localhost" in its request — i.e. it lists servers registered on the gateway’s own machine, not on whatever machine bhtune itself happens to run on. That is exactly right for this topology (the gateway runs next to the OPC DA server; bhtune runs wherever the engineer’s browser or scheduler is) and is called out here so it is never mistaken for a bug.