Commit 52328d9b authored by hezhuozhi's avatar hezhuozhi

Merge remote-tracking branch 'origin/developer' into developer

parents db6ce7a2 689d9332
......@@ -39,7 +39,7 @@ public class HandleESMessage2TDService {
/**
* 十分钟拉取ES数据存入TdEngine
*/
@Scheduled(cron = "0 */2 * * * ?")
@Scheduled(cron = "0 */10 * * * ?")
@Transactional(rollbackFor = Exception.class)
public void syncEsData2TDEngine() throws Exception {
SimpleDateFormat format = new SimpleDateFormat(datePattern);
......@@ -56,7 +56,7 @@ public class HandleESMessage2TDService {
try {
HashMap<String, String> syncFlag = new HashMap<>();
syncFlag.put("sync_flag", "success");
emqKeeper.getMqttClient().publish("sync_esdata_to_tdengine_notice1", JSON.toJSONString(syncFlag).getBytes(), 0, false);
emqKeeper.getMqttClient().publish("sync_esdata_to_tdengine_notice", JSON.toJSONString(syncFlag).getBytes(), 0, false);
log.info("同步ES数据至发发送消息给业务发送通知成功!");
} catch (Exception exception) {
log.info("同步ES数据至发发送消息给业务发送通知失败!");
......
......@@ -100,7 +100,7 @@ public class IdxBizFanHealthIndexServiceImpl extends BaseService<IdxBizFanHealth
tdid=address+"_"+idxBizFanPointProcessVariableClassification.getGatewayId();
}
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'");
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
Calendar calendar = Calendar.getInstance(TimeZone.getTimeZone("UTC"));
sdf.setTimeZone(TimeZone.getTimeZone("UTC"));
//限制必须是区间时间段
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment