Files
ldb/ebpf/c/replica.h

28 lines
414 B
C
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#ifndef __REPLICA_H__
#define __REPLICA_H__
#define MAX_IP_LEN 64
enum {
EVENT_SSYNC = 1,
EVENT_SREADY = 2,
};
struct replica_event {
uint32_t type;
uint32_t _pad;
union {
struct {
uint64_t seq; // SYNC_SEQ从这个 seq 开始增量
int32_t port;
uint32_t ip_len;
char ip[MAX_IP_LEN];
} sync;
};
};
#endif