public final class TmNettyRemotingClient extends AbstractNettyRemotingClient
basketMap, enableClientBatchSendRequest, mergeLock, mergeMsgMapfutures, idGenerator, isSending, lock, messageExecutor, nowMills, processorTable, rpcHooks, timerExecutor| Modifier and Type | Method and Description |
|---|---|
void |
destroy() |
static TmNettyRemotingClient |
getInstance()
Gets instance.
|
static TmNettyRemotingClient |
getInstance(String applicationId,
String transactionServiceGroup)
Gets instance.
|
static TmNettyRemotingClient |
getInstance(String applicationId,
String transactionServiceGroup,
String accessKey,
String secretKey)
Gets instance.
|
protected Function<String,NettyPoolKey> |
getPoolKeyFunction()
Get pool key function.
|
long |
getRpcRequestTimeout()
get Rpc Request Timeout
|
String |
getTransactionServiceGroup()
Get transaction service group.
|
void |
init() |
boolean |
isEnableClientBatchSendRequest()
Whether to enable batch sending of requests, hand over to subclass implementation.
|
void |
onRegisterMsgFail(String serverAddress,
io.netty.channel.Channel channel,
Object response,
AbstractMessage requestMessage)
On register msg fail.
|
void |
onRegisterMsgSuccess(String serverAddress,
io.netty.channel.Channel channel,
Object response,
AbstractMessage requestMessage)
On register msg success.
|
protected void |
setAccessKey(String accessKey)
Sets access key.
|
void |
setApplicationId(String applicationId)
Sets application id.
|
protected void |
setSecretKey(String secretKey)
Sets secret key.
|
void |
setTransactionServiceGroup(String transactionServiceGroup)
Sets transaction service group.
|
destroyChannel, doSelect, getClientChannelManager, getTransactionMessageHandler, getXid, loadBalance, registerProcessor, sendAsyncRequest, sendAsyncResponse, sendSyncRequest, sendSyncRequest, setTransactionMessageHandlerbuildRequestMessage, buildResponseMessage, destroyChannel, doAfterRpcHooks, doBeforeRpcHooks, getAddressFromChannel, getAddressFromContext, getFutures, getGroup, getNextMessageId, processMessage, sendAsync, sendSync, setGrouppublic static TmNettyRemotingClient getInstance(String applicationId, String transactionServiceGroup)
applicationId - the application idtransactionServiceGroup - the transaction service grouppublic static TmNettyRemotingClient getInstance(String applicationId, String transactionServiceGroup, String accessKey, String secretKey)
applicationId - the application idtransactionServiceGroup - the transaction service groupaccessKey - the access keysecretKey - the secret keypublic static TmNettyRemotingClient getInstance()
public void setApplicationId(String applicationId)
applicationId - the application idpublic void setTransactionServiceGroup(String transactionServiceGroup)
transactionServiceGroup - the transaction service groupprotected void setAccessKey(String accessKey)
accessKey - the access keyprotected void setSecretKey(String secretKey)
secretKey - the secret keypublic void init()
init in class AbstractNettyRemotingClientpublic String getTransactionServiceGroup()
AbstractNettyRemotingClientgetTransactionServiceGroup in class AbstractNettyRemotingClientpublic boolean isEnableClientBatchSendRequest()
AbstractNettyRemotingClientisEnableClientBatchSendRequest in class AbstractNettyRemotingClientpublic long getRpcRequestTimeout()
AbstractNettyRemotingClientgetRpcRequestTimeout in class AbstractNettyRemotingClientpublic void onRegisterMsgSuccess(String serverAddress, io.netty.channel.Channel channel, Object response, AbstractMessage requestMessage)
RemotingClientserverAddress - the server addresschannel - the channelresponse - the responserequestMessage - the request messagepublic void onRegisterMsgFail(String serverAddress, io.netty.channel.Channel channel, Object response, AbstractMessage requestMessage)
RemotingClientserverAddress - the server addresschannel - the channelresponse - the responserequestMessage - the request messagepublic void destroy()
destroy in interface Disposabledestroy in class AbstractNettyRemotingClientprotected Function<String,NettyPoolKey> getPoolKeyFunction()
AbstractNettyRemotingClientgetPoolKeyFunction in class AbstractNettyRemotingClientCopyright © 2023 Seata. All rights reserved.