T
- the type of message to be sentpublic class DefaultInstructionAckSource<T> extends Object implements InstructionAckSource<T>
InstructionAckSource
.Constructor and Description |
---|
DefaultInstructionAckSource(Function<io.axoniq.axonserver.grpc.InstructionAck,T> messageCreator)
Instantiates
DefaultInstructionAckSource . |
Modifier and Type | Method and Description |
---|---|
void |
sendAck(String instructionId,
boolean success,
io.axoniq.axonserver.grpc.ErrorMessage error,
io.grpc.stub.StreamObserver<T> stream)
Sends an acknowledgement.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
sendSuccessfulAck, sendUnsuccessfulAck, sendUnsupportedInstruction
public DefaultInstructionAckSource(Function<io.axoniq.axonserver.grpc.InstructionAck,T> messageCreator)
DefaultInstructionAckSource
.messageCreator
- creates a message based on InstructionAck
public void sendAck(String instructionId, boolean success, io.axoniq.axonserver.grpc.ErrorMessage error, io.grpc.stub.StreamObserver<T> stream)
InstructionAckSource
sendAck
in interface InstructionAckSource<T>
instructionId
- identifier of successful instruction. If null
, acknowledgement will not be sent.success
- true
if acknowledgement is successful, false
otherwiseerror
- the cause of the error. Provide null
for successful acknowledgementstream
- the stream for sending acknowledgementsCopyright © 2010–2020. All rights reserved.