提交 a7e88534 authored 作者: blu's avatar blu

big refacting of communitation architect

上级 962b89d1
......@@ -255,10 +255,10 @@ protected:
bStopSig = true;
break;
}
if(1 == getppid()) {
spdlog::error("evmgr {} exit since evdaemon is dead", devSn);
exit(1);
}
// if(1 == getppid()) {
// spdlog::error("evmgr {} exit since evdaemon is dead", devSn);
// exit(1);
// }
auto body = z_recv_multiple(pRouter,false);
if(body.size() == 0) {
spdlog::error("evmgr {} failed to receive multiple msg: {}", devSn, zmq_strerror(zmq_errno()));
......
......@@ -585,10 +585,10 @@ protected:
bStopSig = true;
break;
}
if(1 == getppid()) {
spdlog::error("evmlmotion {} exit since evdaemon is dead", selfId);
exit(1);
}
// if(1 == getppid()) {
// spdlog::error("evmlmotion {} exit since evdaemon is dead", selfId);
// exit(1);
// }
// business logic
int ret =zmq_msg_init(&msg);
......
......@@ -306,10 +306,10 @@ protected:
break;
}
if(1 == getppid()) {
spdlog::error("evpuller {} exit since evdaemon is dead", selfId);
exit(1);
}
// if(1 == getppid()) {
// spdlog::error("evpuller {} exit since evdaemon is dead", selfId);
// exit(1);
// }
AVStream *in_stream;
AVPacket packet;
......
......@@ -321,10 +321,10 @@ protected:
break;
}
if(1 == getppid()) {
spdlog::error("evpusher {} exit since evdaemon is dead", selfId);
exit(1);
}
// if(1 == getppid()) {
// spdlog::error("evpusher {} exit since evdaemon is dead", selfId);
// exit(1);
// }
ret =zmq_msg_init(&msg);
if(ret != 0) {
......
......@@ -362,10 +362,10 @@ protected:
break;
}
if(1 == getppid()) {
spdlog::error("evmgr {} exit since evdaemon is dead", selfId);
exit(1);
}
// if(1 == getppid()) {
// spdlog::error("evmgr {} exit since evdaemon is dead", selfId);
// exit(1);
// }
// business logic
int ret =zmq_msg_init(&msg);
......
......@@ -182,7 +182,7 @@ namespace cfgutils {
if(modules.count(modName) != 0) {
json &ml = modules[modName];
for(auto &m : ml) {
if(m["sn"] == sn && m["iid"] == iid && m["enabled"] != 0) {
if(m["sn"] == sn && to_string(m["iid"]) == iid && m["enabled"] != 0) {
ret = &v;
break;
}
......@@ -192,7 +192,7 @@ namespace cfgutils {
if(modules.count("evml") != 0) {
json &ml = modules["evml"];
for(auto &m: ml) {
if(subMn == m["type"] && m[iid] == iid && m["sn"] == sn && m["enabled"] != 0) {
if(subMn == m["type"] && to_string(m[iid]) == iid && m["sn"] == sn && m["enabled"] != 0) {
ret = &v;
break;
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论