use set_real_state_count
This commit is contained in:
@@ -37,6 +37,8 @@
|
||||
#include "interface.h"
|
||||
#include "front.h"
|
||||
|
||||
#include "../../client2.h"
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
using namespace std;
|
||||
@@ -876,11 +878,13 @@ rocketmq::ConsumeStatus myMessageCallbackrtdata(const rocketmq::MQMessageExt& ms
|
||||
}
|
||||
|
||||
// 写入 XML
|
||||
if (!createXmlFile(dev_index, mp_index, realData, soeData, limit, "new")) {
|
||||
/*if (!createXmlFile(dev_index, mp_index, realData, soeData, limit, "new")) {
|
||||
DIY_ERRORLOG("process", "【ERROR】前置无法创建实时数据触发文件");
|
||||
std::cerr << "Failed to create the XML file." << std::endl;
|
||||
return rocketmq::RECONSUME_LATER;
|
||||
}
|
||||
}*/
|
||||
//不再使用文件触发方式,直接调用接口向终端发起请求
|
||||
ClientManager::instance().set_real_state_count(devid, 60,mp_index);//一秒询问一次,询问60次
|
||||
|
||||
return rocketmq::CONSUME_SUCCESS;
|
||||
}
|
||||
@@ -1009,7 +1013,7 @@ rocketmq::ConsumeStatus myMessageCallbackrecall(const rocketmq::MQMessageExt& ms
|
||||
if (!result.empty()) {
|
||||
|
||||
std::lock_guard<std::mutex> lock(ledgermtx);
|
||||
recall_json_handle(result);
|
||||
recall_json_handle(result);//不再使用文件补招方式
|
||||
|
||||
} else {
|
||||
std::cerr << "recall data is NULL." << std::endl;
|
||||
|
||||
Reference in New Issue
Block a user