接口 SendCallback
public interface SendCallback
-
方法概要
修饰符和类型方法说明void
addCallback
(MessageImpl<?> msg, SendCallback scb) used to specify a callback to be invoked on completion of a send operation for individual messages sent in a batch.CompletableFuture<org.apache.pulsar.client.api.MessageId>
MessageImpl<?>
Return next message in chain.void
invoked when send operation completes.
-
方法详细资料
-
sendComplete
invoked when send operation completes.- 参数:
e
-
-
addCallback
used to specify a callback to be invoked on completion of a send operation for individual messages sent in a batch. Callbacks for messages in a batch get chained- 参数:
msg
- message sentscb
- callback associated with the message
-
getNextSendCallback
SendCallback getNextSendCallback()- 返回:
- next callback in chain
-
getNextMessage
MessageImpl<?> getNextMessage()Return next message in chain.- 返回:
- next message in chain
-
getFuture
CompletableFuture<org.apache.pulsar.client.api.MessageId> getFuture()- 返回:
- future associated with callback
-