File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2828> 如果库安装编译本仓库的时候有错误或者需要确认版本信息,可以在issue页面查看其他人遇到的问题和分享: [ 链接] ( https://github.com/youngyangyang04/KVstorageBaseRaft-cpp/issues )
2929
3030### 2.编译启动
31- #### 使用rpc
31+
32+ #### 先启动rpc
3233```
3334cd KVstorageBaseRaft-cpp // 进入项目目录
3435mkdir cmake-build-debug
4546./provider
4647```
4748
49+ ![ ] ( docs/images/rpc1.jpg )
50+
51+
4852换一个窗口,在执行 consumer
4953
5054```
5155./consumer
5256```
5357
58+ ![ ] ( docs/images/rpc2.jpg )
59+
5460运行即可,注意先运行provider,再运行consumer,原因很简单:需要先提供rpc服务,才能去调用。
5561
5662
5763#### 使用raft集群
58- ```
59- mkdir cmake-build-debug
60- cd cmake-build-debug
61- cmake..
62- make
63- ```
6464之后在目录bin就有对应的可执行文件生成,
6565```
6666// make sure you in bin directory ,and this has a test.conf file
67- raftCoreRun -n 3 -f test.conf
67+ ./ raftCoreRun -n 3 -f test.conf
6868```
6969
70+ ![ ] ( docs/images/raft.jpg )
71+
7072这里更推荐一键运行,使用clion/clion nova,点击这个按钮即可:
7173
7274![ img.png] ( docs/images/img.png )
You can’t perform that action at this time.
0 commit comments