Merge branch 'dev-new' into dev-new-rabbitmq

This commit is contained in:
Guoqs
2024-11-22 14:21:58 +08:00
43 changed files with 1859 additions and 445 deletions

View File

@@ -7,6 +7,7 @@ import com.jsowell.common.enums.ykc.PileConnectorDataBaseStatusEnum;
import com.jsowell.common.util.StringUtils;
import com.jsowell.common.util.YKCUtils;
import com.jsowell.netty.factory.YKCOperateFactory;
import com.jsowell.netty.factory.YKCOperateFactoryV2;
import com.jsowell.netty.handler.yunkuaichong.AbstractYkcHandler;
import com.jsowell.netty.service.yunkuaichong.YKCBusinessService;
import com.jsowell.pile.service.OrderBasicInfoService;
@@ -31,6 +32,9 @@ public class YKCBusinessServiceImpl implements YKCBusinessService {
@Autowired
private OrderBasicInfoService orderBasicInfoService;
@Autowired
private YKCOperateFactoryV2 ykcOperateFactoryV2; // 使用注解注入
@Override
public byte[] process(byte[] msg, ChannelHandlerContext ctx) {
if (!YKCUtils.checkMsg(msg)) {
@@ -42,6 +46,7 @@ public class YKCBusinessServiceImpl implements YKCBusinessService {
String frameType = YKCUtils.frameType2Str(ykcDataProtocol.getFrameType());
// 获取业务处理handler
AbstractYkcHandler invokeStrategy = YKCOperateFactory.getInvokeStrategy(frameType);
// AbstractYkcHandlerV2 invokeStrategy = ykcOperateFactoryV2.getInvokeStrategy(frameType);
return invokeStrategy.supplyProcess(ykcDataProtocol, ctx);
}