Class GridClientFactory


  • public class GridClientFactory
    extends Object
    Client factory opens and closes clients. It also tracks all currently opened clients as well.
    • Method Detail

      • stopAll

        public static void stopAll()
        Waits for all open clients to finish their operations and stops them, This method is equivalent to stopAll(true) method invocation.
        See Also:
        stopAll(boolean)
      • stopAll

        public static void stopAll​(boolean wait)
        Stops all currently open clients.
        Parameters:
        wait - If true then each client will wait to finish all ongoing requests before closing (however, no new requests will be accepted). If false, clients will be closed immediately and all ongoing requests will be failed.
      • stop

        public static void stop​(UUID clientId)
        Waits for all pending requests for a particular client to be completed (no new requests will be accepted) and then closes the client. This method is equivalent to stop(clientId, true).
        Parameters:
        clientId - Identifier of client to close.
        See Also:
        stop(UUID, boolean)
      • stop

        public static void stop​(UUID clientId,
                                boolean wait)
        Stops particular client.
        Parameters:
        clientId - Client identifier to close.
        wait - If true then client will wait to finish all ongoing requests before closing (however, no new requests will be accepted). If false, client will be closed immediately and all ongoing requests will be failed.