Class DurableTaskGrpcWorkerBuilder


  • public final class DurableTaskGrpcWorkerBuilder
    extends java.lang.Object
    Builder object for constructing customized DurableTaskGrpcWorker instances.
    • Constructor Detail

      • DurableTaskGrpcWorkerBuilder

        public DurableTaskGrpcWorkerBuilder()
    • Method Detail

      • grpcChannel

        public DurableTaskGrpcWorkerBuilder grpcChannel​(io.grpc.Channel channel)
        Sets the gRPC channel to use for communicating with the sidecar process.

        This builder method allows you to provide your own gRPC channel for communicating with the Durable Task sidecar endpoint. Channels provided using this method won't be closed when the worker is closed. Rather, the caller remains responsible for shutting down the channel after disposing the worker.

        If not specified, a gRPC channel will be created automatically for each constructed DurableTaskGrpcWorker.

        Parameters:
        channel - the gRPC channel to use
        Returns:
        this builder object
      • port

        public DurableTaskGrpcWorkerBuilder port​(int port)
        Sets the gRPC endpoint port to connect to. If not specified, the default Durable Task port number will be used.
        Parameters:
        port - the gRPC endpoint port to connect to
        Returns:
        this builder object
      • maximumTimerInterval

        public DurableTaskGrpcWorkerBuilder maximumTimerInterval​(java.time.Duration maximumTimerInterval)
        Sets the maximum timer interval. If not specified, the default maximum timer interval duration will be used. The default maximum timer interval duration is 3 days.
        Parameters:
        maximumTimerInterval - the maximum timer interval
        Returns:
        this builder object