Merge remote-tracking branch 'origin/3.0' into enh/opt-transport
This commit is contained in:
parent
fb059dbdd0
commit
10884dd534
|
@ -971,11 +971,6 @@ typedef struct SEpSet {
|
||||||
SEp eps[TSDB_MAX_REPLICA];
|
SEp eps[TSDB_MAX_REPLICA];
|
||||||
} SEpSet;
|
} SEpSet;
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
int8_t inUse;
|
|
||||||
int8_t numOfEps;
|
|
||||||
SEp eps[];
|
|
||||||
} SReqEpSet;
|
|
||||||
|
|
||||||
int32_t tEncodeSEpSet(SEncoder* pEncoder, const SEpSet* pEp);
|
int32_t tEncodeSEpSet(SEncoder* pEncoder, const SEpSet* pEp);
|
||||||
int32_t tDecodeSEpSet(SDecoder* pDecoder, SEpSet* pEp);
|
int32_t tDecodeSEpSet(SDecoder* pDecoder, SEpSet* pEp);
|
||||||
|
|
|
@ -136,35 +136,13 @@ typedef struct SCvtAddr {
|
||||||
bool cvt;
|
bool cvt;
|
||||||
} SCvtAddr;
|
} SCvtAddr;
|
||||||
|
|
||||||
int32_t transCreateReqEpsetFromUserEpset(const SEpSet* pEpset, SReqEpSet** pReqEpSet);
|
#pragma pack(push, 1)
|
||||||
int32_t transCreateUserEpsetFromReqEpset(const SReqEpSet* pReqEpSet, SEpSet* pEpSet);
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
SReqEpSet* epSet; // ip list provided by app
|
int8_t inUse;
|
||||||
SReqEpSet* origEpSet;
|
int8_t numOfEps;
|
||||||
void* ahandle; // handle provided by app
|
SEp eps[];
|
||||||
tmsg_t msgType; // message type
|
} SReqEpSet;
|
||||||
|
|
||||||
STransCtx userCtx; //
|
|
||||||
STransMsg* pRsp; // for synchronous API
|
|
||||||
tsem_t* pSem; // for synchronous API
|
|
||||||
STransSyncMsg* pSyncMsg; // for syncchronous with timeout API
|
|
||||||
int64_t syncMsgRef;
|
|
||||||
SCvtAddr* pCvtAddr;
|
|
||||||
|
|
||||||
int64_t retryInitTimestamp;
|
|
||||||
int64_t retryNextInterval;
|
|
||||||
int64_t retryMaxTimeout;
|
|
||||||
int32_t retryMinInterval;
|
|
||||||
int32_t retryMaxInterval;
|
|
||||||
int32_t retryStepFactor;
|
|
||||||
int32_t retryStep;
|
|
||||||
int32_t retryCode;
|
|
||||||
int8_t retryInit;
|
|
||||||
int8_t epsetRetryCnt;
|
|
||||||
} SReqCtx;
|
|
||||||
|
|
||||||
#pragma pack(push, 1)
|
|
||||||
|
|
||||||
#define TRANS_VER 2
|
#define TRANS_VER 2
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
@ -205,6 +183,33 @@ typedef struct {
|
||||||
|
|
||||||
#pragma pack(pop)
|
#pragma pack(pop)
|
||||||
|
|
||||||
|
int32_t transCreateReqEpsetFromUserEpset(const SEpSet* pEpset, SReqEpSet** pReqEpSet);
|
||||||
|
int32_t transCreateUserEpsetFromReqEpset(const SReqEpSet* pReqEpSet, SEpSet* pEpSet);
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
SReqEpSet* epSet; // ip list provided by app
|
||||||
|
SReqEpSet* origEpSet;
|
||||||
|
void* ahandle; // handle provided by app
|
||||||
|
tmsg_t msgType; // message type
|
||||||
|
|
||||||
|
STransCtx userCtx; //
|
||||||
|
STransMsg* pRsp; // for synchronous API
|
||||||
|
tsem_t* pSem; // for synchronous API
|
||||||
|
STransSyncMsg* pSyncMsg; // for syncchronous with timeout API
|
||||||
|
int64_t syncMsgRef;
|
||||||
|
SCvtAddr* pCvtAddr;
|
||||||
|
|
||||||
|
int64_t retryInitTimestamp;
|
||||||
|
int64_t retryNextInterval;
|
||||||
|
int64_t retryMaxTimeout;
|
||||||
|
int32_t retryMinInterval;
|
||||||
|
int32_t retryMaxInterval;
|
||||||
|
int32_t retryStepFactor;
|
||||||
|
int32_t retryStep;
|
||||||
|
int32_t retryCode;
|
||||||
|
int8_t retryInit;
|
||||||
|
int8_t epsetRetryCnt;
|
||||||
|
} SReqCtx;
|
||||||
typedef enum { Normal, Quit, Release, Register, Update, FreeById } STransMsgType;
|
typedef enum { Normal, Quit, Release, Register, Update, FreeById } STransMsgType;
|
||||||
typedef enum { ConnNormal, ConnAcquire, ConnRelease, ConnBroken, ConnInPool } ConnStatus;
|
typedef enum { ConnNormal, ConnAcquire, ConnRelease, ConnBroken, ConnInPool } ConnStatus;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue