Skip to main content

serve

Function serve 

Source
pub async fn serve(
    config: Config,
    factory: Factory,
    listener: TcpListener,
    shutdown: impl Future<Output = ()> + Send + 'static,
) -> Result<(), String>
Expand description

Serves on listener until shutdown completes, then closes the WebSockets, releases every pressed button, stops the PLC workers (their queued writes still go out) and flushes the audit log.