Package io.camunda.client.impl.command
Class TopologyRequestImpl
java.lang.Object
io.camunda.client.impl.command.TopologyRequestImpl
- All Implemented Interfaces:
CommandWithCommunicationApiStep<TopologyRequestStep1>,FinalCommandStep<Topology>,TopologyRequestStep1
-
Constructor Summary
ConstructorsConstructorDescriptionTopologyRequestImpl(io.camunda.zeebe.gateway.protocol.GatewayGrpc.GatewayStub asyncStub, HttpClient httpClient, Duration requestTimeout, Predicate<CredentialsProvider.StatusCode> retryPredicate, boolean useRest) -
Method Summary
Modifier and TypeMethodDescriptionrequestTimeout(Duration requestTimeout) Sets the request timeout for the command.send()Sends the command to the Camunda gateway.useGrpc()Sets gRPC as the communication API for this command.useRest()Sets REST as the communication API for this command.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.camunda.client.api.command.FinalCommandStep
execute
-
Constructor Details
-
TopologyRequestImpl
public TopologyRequestImpl(io.camunda.zeebe.gateway.protocol.GatewayGrpc.GatewayStub asyncStub, HttpClient httpClient, Duration requestTimeout, Predicate<CredentialsProvider.StatusCode> retryPredicate, boolean useRest)
-
-
Method Details
-
useRest
Description copied from interface:CommandWithCommunicationApiStepSets REST as the communication API for this command. If this command doesn't support communication over REST, it simply returns the command builder instance unchanged. The default communication API can be configured usingCamundaClientBuilder.preferRestOverGrpc(boolean).- Specified by:
useRestin interfaceCommandWithCommunicationApiStep<TopologyRequestStep1>- Returns:
- the configured command
-
useGrpc
Description copied from interface:CommandWithCommunicationApiStepSets gRPC as the communication API for this command. If this command doesn't support communication over gRPC, it simply returns the command builder instance unchanged. The default communication API can be configured usingCamundaClientBuilder.preferRestOverGrpc(boolean).- Specified by:
useGrpcin interfaceCommandWithCommunicationApiStep<TopologyRequestStep1>- Returns:
- the configured command
-
requestTimeout
Description copied from interface:FinalCommandStepSets the request timeout for the command. The default request timeout can be configured usingCamundaClientBuilder.defaultRequestTimeout(Duration).- Specified by:
requestTimeoutin interfaceFinalCommandStep<Topology>- Parameters:
requestTimeout- the request timeout- Returns:
- the configured command
-
send
Description copied from interface:FinalCommandStepSends the command to the Camunda gateway. This operation is asynchronous. In case of success, the future returns the event that was generated by the Camunda gateway in response to the command.Call
CamundaFuture.join()to wait until the response is available.Future<JobEventinvalid input: '>' future = command.send(); JobEvent event = future.join();- Specified by:
sendin interfaceFinalCommandStep<Topology>- Returns:
- a future tracking state of success/failure of the command.
-