mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 02:55:04 +08:00
update
This commit is contained in:
@@ -214,7 +214,7 @@ public class YKCUtils {
|
||||
// 保存桩号和channel的关系
|
||||
PileChannelEntity.checkChannel(pileSn, ctx);
|
||||
|
||||
PileChannelEntity.checkChannelV2(pileSn, ctx);
|
||||
// PileChannelEntity.checkChannelV2(pileSn, ctx);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -70,7 +70,7 @@ public abstract class AbstractYkcHandler implements InitializingBean {
|
||||
// 保存桩号和channel的关系
|
||||
PileChannelEntity.checkChannel(pileSn, ctx);
|
||||
|
||||
PileChannelEntity.checkChannelV2(pileSn, ctx);
|
||||
// PileChannelEntity.checkChannelV2(pileSn, ctx);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -307,7 +307,7 @@ public class NettyServerHandler extends ChannelInboundHandlerAdapter {
|
||||
}
|
||||
log.error("【{}】发生了错误, pileSn:【{}】此连接被关闭, 此时连通数量: {}", channelId, pileSn, CHANNEL_MAP.size());
|
||||
// 删除连接
|
||||
PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
// PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
ctx.channel().close();
|
||||
}
|
||||
} finally {
|
||||
|
||||
@@ -88,7 +88,7 @@ public class YKCBusinessServiceImpl implements YKCBusinessService {
|
||||
pileMsgRecordService.save(pileSn, pileSn, type, jsonMsg, "");
|
||||
|
||||
// 删除连接
|
||||
PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
// PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
|
||||
// 删除桩编号和channel的关系
|
||||
// PileChannelEntity.removeByPileSn(pileSn);
|
||||
|
||||
@@ -126,14 +126,14 @@ public class YKCPushCommandServiceImpl implements YKCPushCommandService {
|
||||
log.error("push发送命令失败, pileSn:{}", pileSn, cause);
|
||||
|
||||
// 异步删除Map中的保存关系(带关闭连接)
|
||||
CompletableFuture.runAsync(() -> {
|
||||
try {
|
||||
// 删除Map中的保存关系
|
||||
PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
} catch (Exception e) {
|
||||
log.error("异步删除、关闭连接 error", e);
|
||||
}
|
||||
}, executor);
|
||||
// CompletableFuture.runAsync(() -> {
|
||||
// try {
|
||||
// // 删除Map中的保存关系
|
||||
// PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
// } catch (Exception e) {
|
||||
// log.error("异步删除、关闭连接 error", e);
|
||||
// }
|
||||
// }, executor);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -231,14 +231,14 @@ public class YKCPushCommandServiceImpl implements YKCPushCommandService {
|
||||
log.error("push发送命令失败, pileSn:{}", pileSn, cause);
|
||||
|
||||
// 异步删除Map中的保存关系(带关闭连接)
|
||||
CompletableFuture.runAsync(() -> {
|
||||
try {
|
||||
// 删除Map中的保存关系
|
||||
PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
} catch (Exception e) {
|
||||
log.error("异步删除、关闭连接 error", e);
|
||||
}
|
||||
}, executor);
|
||||
// CompletableFuture.runAsync(() -> {
|
||||
// try {
|
||||
// // 删除Map中的保存关系
|
||||
// PileChannelEntity.deleteChannel(pileSn, ctx);
|
||||
// } catch (Exception e) {
|
||||
// log.error("异步删除、关闭连接 error", e);
|
||||
// }
|
||||
// }, executor);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user