|
|
|
@ -205,14 +205,22 @@ public class NettyServer { |
|
|
|
command = Integer.parseInt(root.element("Command").getText()); |
|
|
|
} |
|
|
|
|
|
|
|
logger.info(Color.MAGENTA + "######## <= 会话: {}, 客户: {}, 消息类型: {}, 命令:{}, 消息体: ########\n{}" + Color.END, binaryModel.uuid, binaryModel.id, type, command, xml); |
|
|
|
// logger.info(Color.MAGENTA + "######## <= 会话: {}, 客户: {}, 消息类型: {}, 命令:{}, 消息体: ########\n{}" + Color.END, binaryModel.uuid, binaryModel.id, type, command, xml); |
|
|
|
//判断是否重发 |
|
|
|
if (type == SystemType.system) { |
|
|
|
if (command == SystemType.has_response || command == SystemType.no_response) { |
|
|
|
if (null != root.element("Code")) { |
|
|
|
if (root.element("Code").getText() == ResponseType.retry) { |
|
|
|
String code = root.element("Code").getText(); |
|
|
|
if (code.equals(ResponseType.retry)) { |
|
|
|
resetSendMsg(binaryModel.receiveIndex, sendCode); |
|
|
|
} else if (code.equals(ResponseType.succeed)) { |
|
|
|
logger.info("######## 响应结果为成功, 客户: {}, 命令: {}, 消息体 ########\n{}", binaryModel.id, command, xml); |
|
|
|
} else if (code.equals(ResponseType.fault)) { |
|
|
|
logger.warn("######## 响应结果为失败, 客户: {}, 命令: {}, 消息体 ########\n{}", binaryModel.id, command, xml); |
|
|
|
} else if (code.equals(ResponseType.reject)) { |
|
|
|
logger.warn("######## 响应结果为拒绝, 客户: {}, 命令: {}, 消息体 ########\n{}", binaryModel.id, command, xml); |
|
|
|
} |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|