remove SWalHead in tsync.h

This commit is contained in:
Jeff Tao 2020-04-08 09:40:20 +08:00
parent 3c77d2c399
commit e1a3d7f295
1 changed files with 7 additions and 16 deletions

View File

@ -36,27 +36,12 @@ typedef enum _TAOS_SYNC_STATUS {
TAOS_SYNC_STATUS_CACHE, TAOS_SYNC_STATUS_CACHE,
} ESyncStatus; } ESyncStatus;
typedef struct {
int8_t msgType;
int8_t reserved[3];
int32_t len;
uint64_t version;
uint64_t cksum;
char cont[];
} SWalHead;
typedef struct { typedef struct {
uint32_t nodeId; // node ID assigned by TDengine uint32_t nodeId; // node ID assigned by TDengine
uint32_t nodeIp; // node IP address uint32_t nodeIp; // node IP address
char name[TSDB_FILENAME_LEN]; // external node name char name[TSDB_FILENAME_LEN]; // external node name
} SNodeInfo; } SNodeInfo;
typedef struct {
int selfIndex;
uint32_t nodeId[TAOS_SYNC_MAX_REPLICA];
int role[TAOS_SYNC_MAX_REPLICA];
} SNodesRole;
typedef struct { typedef struct {
uint32_t arbitratorIp; // arbitrator IP address uint32_t arbitratorIp; // arbitrator IP address
int8_t quorum; // number of confirms required, >=1 int8_t quorum; // number of confirms required, >=1
@ -64,6 +49,12 @@ typedef struct {
SNodeInfo nodeInfo[TAOS_SYNC_MAX_REPLICA]; SNodeInfo nodeInfo[TAOS_SYNC_MAX_REPLICA];
} SSyncCfg; } SSyncCfg;
typedef struct {
int selfIndex;
uint32_t nodeId[TAOS_SYNC_MAX_REPLICA];
int role[TAOS_SYNC_MAX_REPLICA];
} SNodesRole;
typedef struct { typedef struct {
char label[20]; // for debug purpose char label[20]; // for debug purpose
char path[128]; // path to the file char path[128]; // path to the file