xjlgod commented on code in PR #7346: URL: https://github.com/apache/incubator-seata/pull/7346#discussion_r2097892798
########## core/src/main/java/org/apache/seata/core/rpc/netty/ProtocolDetectHandler.java: ########## @@ -20,22 +20,19 @@ import io.netty.channel.ChannelHandler; import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.ByteToMessageDecoder; -import org.apache.seata.core.protocol.detector.Http2Detector; import org.apache.seata.core.protocol.detector.ProtocolDetector; -import org.apache.seata.core.protocol.detector.SeataDetector; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import java.util.List; public class ProtocolDetectHandler extends ByteToMessageDecoder { private static final Logger LOGGER = LoggerFactory.getLogger(ProtocolDetectHandler.class); - private NettyServerBootstrap nettyServerBootstrap; + private ProtocolDetector[] supportedProtocolDetectors; - public ProtocolDetectHandler(NettyServerBootstrap nettyServerBootstrap) { - this.nettyServerBootstrap = nettyServerBootstrap; - this.supportedProtocolDetectors = new ProtocolDetector[]{new Http2Detector(nettyServerBootstrap.getChannelHandlers()), new SeataDetector(nettyServerBootstrap.getChannelHandlers())}; + public ProtocolDetectHandler(ProtocolDetector[] supportedProtocolDetectors) { Review Comment: Follow up here with http service? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@seata.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@seata.apache.org For additional commands, e-mail: notifications-h...@seata.apache.org