pub async fn stop_listener(
    canceler: ServerEnd<RecordCancelerMarker>,
    stop_signal: &AtomicBool
) -> Result<(), Error>