mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-21 03:25:12 +08:00
update 打印日志
This commit is contained in:
@@ -28,7 +28,7 @@ public class BMSAbortDuringChargingPhaseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电阶段 BMS 中止===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电阶段 BMS 中止===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class BMSDemandAndChargerOutputHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电过程 BMS 需求与充电机输出===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电过程 BMS 需求与充电机输出===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class BMSInformationHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电过程 BMS 信息===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电过程 BMS 信息===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ public class BillingTemplateRequestHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===执行计费模板请求逻辑===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===执行计费模板请求逻辑===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体(此请求消息体只有桩编码)
|
||||
byte[] pileSnByte = ykcDataProtocol.getMsgBody();
|
||||
String pileSn = BytesUtil.binary(pileSnByte, 16);
|
||||
|
||||
@@ -27,7 +27,7 @@ public class BillingTemplateResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===执行计费模型设置应答逻辑===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===执行计费模型设置应答逻辑===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class BillingTemplateSettingHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===执行计费模型设置逻辑===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===执行计费模型设置逻辑===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ public class BillingTemplateValidateRequestHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===执行计费模板验证请求逻辑===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===执行计费模板验证请求逻辑===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ public class ChargeEndHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===执行充电结束逻辑===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===执行充电结束逻辑===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class ChargerAbortedDuringChargingPhaseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电阶段充电机中止===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电阶段充电机中止===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class ChargingHandshakeHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===执行充电握手逻辑===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===执行充电握手逻辑===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.jsowell.netty.handler;
|
||||
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.google.common.primitives.Bytes;
|
||||
import com.jsowell.common.constant.Constants;
|
||||
import com.jsowell.common.core.domain.ykc.ConfirmStartChargingData;
|
||||
@@ -18,9 +18,9 @@ import com.jsowell.pile.domain.MemberPlateNumberRelation;
|
||||
import com.jsowell.pile.domain.PileAuthCard;
|
||||
import com.jsowell.pile.dto.GenerateOrderDTO;
|
||||
import com.jsowell.pile.service.MemberPlateNumberRelationService;
|
||||
import com.jsowell.pile.service.PileMsgRecordService;
|
||||
import com.jsowell.pile.service.OrderBasicInfoService;
|
||||
import com.jsowell.pile.service.PileAuthCardService;
|
||||
import com.jsowell.pile.service.PileMsgRecordService;
|
||||
import io.netty.channel.Channel;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -59,7 +59,7 @@ public class ConfirmStartChargingRequestHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电桩主动申请启动充电===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电桩主动申请启动充电===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
@@ -254,7 +254,7 @@ public class ConfirmStartChargingRequestHandler extends AbstractHandler{
|
||||
// accountBalanceByteArr = BytesUtil.checkLengthAndBehindAppendZero(accountBalanceByteArr, 8);
|
||||
|
||||
// 保存报文
|
||||
String jsonMsg = JSONObject.toJSONString(confirmStartChargingData);
|
||||
String jsonMsg = JSON.toJSONString(confirmStartChargingData);
|
||||
pileMsgRecordService.save(pileSn, pileSn, type, jsonMsg, ykcDataProtocol.getHEXString());
|
||||
|
||||
// 拼装消息体
|
||||
|
||||
@@ -28,7 +28,7 @@ public class ErrorMessageHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===错误报文===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===错误报文===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@ public class GroundLockDataUploadHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===地锁数据上送===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===地锁数据上送===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ public class HeartbeatRequestHandler extends AbstractHandler {
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电桩心跳包===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电桩心跳包===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.jsowell.netty.handler;
|
||||
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.google.common.collect.Lists;
|
||||
import com.google.common.primitives.Bytes;
|
||||
import com.jsowell.common.constant.Constants;
|
||||
@@ -244,7 +244,7 @@ public class LoginRequestHandler extends AbstractHandler {
|
||||
CompletableFuture.runAsync(() -> {
|
||||
// 保存报文 没有登录认证通过还要不要保存报文?
|
||||
try {
|
||||
String jsonMsg = JSONObject.toJSONString(loginRequestData);
|
||||
String jsonMsg = JSON.toJSONString(loginRequestData);
|
||||
pileMsgRecordService.save(pileSn, pileSn, type, jsonMsg, ykcDataProtocol.getHEXString());
|
||||
} catch (Exception e) {
|
||||
log.error("保存报文失败pileSn:{}", pileSn, e);
|
||||
|
||||
@@ -28,7 +28,7 @@ public class OfflineCardDataCleaningHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===离线卡数据清除===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===离线卡数据清除===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class OfflineCardDataCleaningResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===离线卡数据清除应答===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===离线卡数据清除应答===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ public class OfflineCardDataQueryHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===离线卡数据查询===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===离线卡数据查询===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编码
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class OfflineCardDataQueryResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===离线卡数据查询应答===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===离线卡数据查询应答===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ public class OfflineCardDataSynchronizationHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===离线卡数据同步===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===离线卡数据同步===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class OfflineCardDataSynchronizationResponseHandler extends AbstractHandl
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===离线卡数据同步应答===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===离线卡数据同步应答===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
//消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ public class ParameterConfigurationHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===参数配置===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===参数配置===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class PileWorkingParameterSettingHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电桩工作参数设置===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电桩工作参数设置===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class PileWorkingParameterSettingResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电桩工作参数设置应答===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电桩工作参数设置应答===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class QueryPileWorkParamsHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[====充电桩査询工作参数回复====] param:{}", JSONObject.toJSONString(ykcDataProtocol));
|
||||
// log.info("[====充电桩査询工作参数回复====] param:{}", JSON.toJSONString(ykcDataProtocol));
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ public class ReadRealTimeMonitorDataHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===读取实时监测数据===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===读取实时监测数据===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
byte[] pileSnByteArr = new byte[]{};
|
||||
|
||||
@@ -27,7 +27,7 @@ public class RemoteAccountBalanceUpdateRequestHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===余额更新应答===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===余额更新应答===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class RemoteControlGroundLockHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===遥控地锁升锁与降锁命令===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===遥控地锁升锁与降锁命令===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编码
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@ public class RemoteControlGroundLockResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===充电桩返回遥控地锁升锁与降锁数据(上行)===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===充电桩返回遥控地锁升锁与降锁数据(上行)===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ public class RemoteIssuedQrCodeHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===后台远程下发二维码前缀指令===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===后台远程下发二维码前缀指令===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编码
|
||||
String pileSn = "88000000000001";
|
||||
|
||||
@@ -27,7 +27,7 @@ public class RemoteIssuedQrCodeResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===桩应答远程下发二维码前缀指令===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===桩应答远程下发二维码前缀指令===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ public class RemoteRestartHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===远程重启===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===远程重启===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.jsowell.netty.handler;
|
||||
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.jsowell.common.core.domain.ykc.YKCDataProtocol;
|
||||
import com.jsowell.common.core.domain.ykc.YKCFrameTypeCode;
|
||||
import com.jsowell.common.util.BytesUtil;
|
||||
@@ -33,7 +33,7 @@ public class RemoteRestartResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===远程重启应答===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===远程重启应答===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
@@ -48,7 +48,7 @@ public class RemoteRestartResponseHandler extends AbstractHandler{
|
||||
saveLastTimeAndCheckChannel(pileSn, channel);
|
||||
|
||||
// 保存报文
|
||||
String jsonMsg = JSONObject.toJSONString(ykcDataProtocol);
|
||||
String jsonMsg = JSON.toJSONString(ykcDataProtocol);
|
||||
pileMsgRecordService.save(pileSn, null, type, jsonMsg, ykcDataProtocol.getHEXString());
|
||||
|
||||
// 设置结果
|
||||
|
||||
@@ -42,7 +42,7 @@ public class RemoteStartChargingRequestHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===远程启动充电命令回复===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===远程启动充电命令回复===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ public class RemoteStopChargingRequestHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===远程停机命令回复===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===远程停机命令回复===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ public class RemoteUpdateHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===远程更新===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===远程更新===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class RemoteUpdateResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[====远程更新应答====] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[====远程更新应答====] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class SettingPileWorkParamsHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[====平台设置工作参数回复====] param:{}", JSONObject.toJSONString(ykcDataProtocol));
|
||||
// log.info("[====平台设置工作参数回复====] param:{}", JSON.toJSONString(ykcDataProtocol));
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ public class TimeCheckSettingHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===对时设置===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===对时设置===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 下发
|
||||
// 桩编号
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ public class TimeCheckSettingResponseHandler extends AbstractHandler{
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===对时设置应答===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===对时设置应答===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.jsowell.netty.handler;
|
||||
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.google.common.primitives.Bytes;
|
||||
import com.jsowell.common.constant.Constants;
|
||||
import com.jsowell.common.core.domain.ykc.TransactionRecordsData;
|
||||
@@ -17,7 +17,9 @@ import com.jsowell.common.util.YKCUtils;
|
||||
import com.jsowell.common.util.id.IdUtils;
|
||||
import com.jsowell.netty.factory.YKCOperateFactory;
|
||||
import com.jsowell.pile.domain.OrderBasicInfo;
|
||||
import com.jsowell.pile.service.*;
|
||||
import com.jsowell.pile.service.OrderBasicInfoService;
|
||||
import com.jsowell.pile.service.PileMerchantInfoService;
|
||||
import com.jsowell.pile.service.PileMsgRecordService;
|
||||
import com.jsowell.pile.service.programlogic.AbstractProgramLogic;
|
||||
import com.jsowell.pile.service.programlogic.ProgramLogicFactory;
|
||||
import com.jsowell.thirdparty.common.CommonService;
|
||||
@@ -316,7 +318,7 @@ public class TransactionRecordsRequestHandler extends AbstractHandler {
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===交易记录===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===交易记录===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// 获取消息体
|
||||
byte[] msgBody = ykcDataProtocol.getMsgBody();
|
||||
|
||||
@@ -550,7 +552,7 @@ public class TransactionRecordsRequestHandler extends AbstractHandler {
|
||||
.build();
|
||||
|
||||
// 保存报文
|
||||
String jsonMsg = JSONObject.toJSONString(data);
|
||||
String jsonMsg = JSON.toJSONString(data);
|
||||
pileMsgRecordService.save(pileSn, pileSn + connectorCode, type, jsonMsg, ykcDataProtocol.getHEXString());
|
||||
|
||||
// 处理订单加锁
|
||||
|
||||
@@ -58,7 +58,7 @@ public class UploadRealTimeMonitorHandler extends AbstractHandler {
|
||||
|
||||
@Override
|
||||
public byte[] supplyProcess(YKCDataProtocol ykcDataProtocol, Channel channel) {
|
||||
// log.info("[===获取桩上传的实时监测数据===] param:{}, channel:{}", JSONObject.toJSONString(ykcDataProtocol), channel.toString());
|
||||
// log.info("[===获取桩上传的实时监测数据===] param:{}, channel:{}", JSON.toJSONString(ykcDataProtocol), channel.toString());
|
||||
RealTimeMonitorData realTimeMonitorData = new RealTimeMonitorData();
|
||||
|
||||
// 获取消息体
|
||||
|
||||
Reference in New Issue
Block a user