namespace ZB.MOM.WW.MxGateway.Server.Workers;

public interface IWorkerStartupProbe
{
    /// <summary>
    /// Waits for the worker process to reach a ready state asynchronously.
    /// </summary>
    /// <param name="process">Worker process to probe.</param>
    /// <param name="request">Worker launch request.</param>
    /// <param name="cancellationToken">Cancellation token.</param>
    /// <returns>Completed task.</returns>
    Task WaitUntilReadyAsync(
        IWorkerProcess process,
        WorkerProcessLaunchRequest request,
        CancellationToken cancellationToken);
}
