recall stat
This commit is contained in:
@@ -98,6 +98,8 @@ extern int TEST_PORT; //测试端口号
|
||||
|
||||
extern std::string FRONT_INST;
|
||||
|
||||
extern bool PQD_FLAG;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////// 功能函数
|
||||
|
||||
template<typename T, typename... Args>
|
||||
@@ -130,6 +132,11 @@ bool parse_param(int argc, char* argv[]) {
|
||||
try {
|
||||
g_front_seg_index = std::stoi(val.substr(0, pos));
|
||||
g_front_seg_num = std::stoi(val.substr(pos + 1));
|
||||
|
||||
if (g_front_seg_index == 0) {
|
||||
PQD_FLAG = true;
|
||||
}
|
||||
|
||||
} catch (...) {
|
||||
std::cerr << "Invalid -s format." << std::endl;
|
||||
}
|
||||
@@ -144,6 +151,11 @@ bool parse_param(int argc, char* argv[]) {
|
||||
try {
|
||||
g_front_seg_index = std::stoi(val.substr(0, pos));
|
||||
g_front_seg_num = std::stoi(val.substr(pos + 1));
|
||||
|
||||
if (g_front_seg_index == 0) {
|
||||
PQD_FLAG = true;
|
||||
}
|
||||
|
||||
} catch (...) {
|
||||
std::cerr << "Invalid -s format." << std::endl;
|
||||
}
|
||||
@@ -223,13 +235,13 @@ std::string get_parent_directory() {
|
||||
//解析模板文件
|
||||
//Set_xml_nodeinfo();
|
||||
|
||||
StartFrontThread(); //开启主线程
|
||||
|
||||
StartMQConsumerThread(); //开启消费者线程
|
||||
|
||||
StartMQProducerThread(); //开启生产者线程
|
||||
|
||||
StartTimerThread(); //开启定时线程
|
||||
if(!PQD_FLAG){
|
||||
StartFrontThread(); //开启主线程
|
||||
StartMQConsumerThread(); //开启消费者线程
|
||||
StartTimerThread(); //开启定时线程
|
||||
}
|
||||
|
||||
//启动worker 根据启动标志启动
|
||||
if(G_TEST_FLAG){
|
||||
|
||||
Reference in New Issue
Block a user