当前位置: 首页 > 工具软件 > PhxPaxos > 使用案例 >

phxpaxos编译示例

芮承运
2023-12-01

官网:Tencent/phxpaxos: The Paxos library implemented in C++ that has been used in the WeChat production environment.

操作如下:

git clone --recursive https://github.com/tencent-wechat/phxpaxos.git
cd phxpaxos
./build.sh
make && make install

编译plugin:

cd plugin
make && make install

编译sample:

cd sample
make

运行:

cd phxecho
mkdir log
./phxecho 127.0.0.1:11111 127.0.0.1:11111,127.0.0.1:11112,127.0.0.1:11113
./phxecho 127.0.0.1:11112 127.0.0.1:11111,127.0.0.1:11112,127.0.0.1:11113
./phxecho 127.0.0.1:11113 127.0.0.1:11111,127.0.0.1:11112,127.0.0.1:11113
hello phxpaxos:)
 类似资料: