接口 TransactionBufferHandler
public interface TransactionBufferHandler
Interface of transaction buffer handler.
-
方法概要
修饰符和类型方法说明voidclose()Release resources.endTxnOnSubscription(String topic, String subscription, long txnIdMostBits, long txnIdLeastBits, TxnAction action, long lowWaterMark) End transaction on subscription.endTxnOnTopic(String topic, long txnIdMostBits, long txnIdLeastBits, TxnAction action, long lowWaterMark) End transaction on topic.intintvoidhandleEndTxnOnSubscriptionResponse(long requestId, CommandEndTxnOnSubscriptionResponse response) Handle response of tend transaction on subscription.voidhandleEndTxnOnTopicResponse(long requestId, CommandEndTxnOnPartitionResponse response) Handle response of end transaction on topic.
-
方法详细资料
-
endTxnOnTopic
CompletableFuture<TxnID> endTxnOnTopic(String topic, long txnIdMostBits, long txnIdLeastBits, TxnAction action, long lowWaterMark) End transaction on topic.- 参数:
topic- topic nametxnIdMostBits- txnIdMostBitstxnIdLeastBits- txnIdLeastBitsaction- transaction action typelowWaterMark- low water mark of this transaction- 返回:
- TxnId
-
endTxnOnSubscription
CompletableFuture<TxnID> endTxnOnSubscription(String topic, String subscription, long txnIdMostBits, long txnIdLeastBits, TxnAction action, long lowWaterMark) End transaction on subscription.- 参数:
topic- topic namesubscription- subscription nametxnIdMostBits- txnIdMostBitstxnIdLeastBits- txnIdLeastBitslowWaterMark- low water mark of this transactionaction- transaction action type- 返回:
- TxnId
-
handleEndTxnOnTopicResponse
Handle response of end transaction on topic.- 参数:
requestId- request IDresponse- response
-
handleEndTxnOnSubscriptionResponse
void handleEndTxnOnSubscriptionResponse(long requestId, CommandEndTxnOnSubscriptionResponse response) Handle response of tend transaction on subscription.- 参数:
requestId- request IDresponse- response
-
close
void close()Release resources. -
getAvailableRequestCredits
int getAvailableRequestCredits() -
getPendingRequestsCount
int getPendingRequestsCount()
-