You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by GitBox <gi...@apache.org> on 2022/03/04 01:35:21 UTC

[GitHub] [incubator-inlong] baomingyu commented on a change in pull request #2881: [INLONG-2880][SDK] Upgrade netty version to 4.x and upgrade log4j to log4j2

baomingyu commented on a change in pull request #2881:
URL: https://github.com/apache/incubator-inlong/pull/2881#discussion_r819199290



##########
File path: inlong-sdk/dataproxy-sdk/src/main/java/org/apache/inlong/sdk/dataproxy/codec/ProtocolDecoder.java
##########
@@ -18,34 +18,31 @@
 
 package org.apache.inlong.sdk.dataproxy.codec;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.channel.ChannelHandlerContext;
+import io.netty.handler.codec.MessageToMessageDecoder;
 import java.nio.charset.StandardCharsets;
 
-import org.jboss.netty.buffer.ChannelBuffer;
-import org.jboss.netty.channel.Channel;
-import org.jboss.netty.channel.ChannelHandlerContext;
-import org.jboss.netty.channel.DefaultExceptionEvent;
-import org.jboss.netty.handler.codec.frame.FrameDecoder;
+import java.util.List;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-public class ProtocolDecoder extends FrameDecoder {
+public class ProtocolDecoder extends MessageToMessageDecoder<ByteBuf> {
 
-    private static final Logger logger = LoggerFactory.getLogger(FrameDecoder.class);
+    private static final Logger logger = LoggerFactory.getLogger(ProtocolDecoder.class);
 
     @Override
-    protected Object decode(ChannelHandlerContext ctx, Channel channel,
-                            ChannelBuffer buffer) throws Exception {
-        //        if(!channel.isConnected()||channel.isReadable()){return null;}
-
+    protected void decode(ChannelHandlerContext var1,

Review comment:
       Automatically generated, unused variables




-- 
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: commits-unsubscribe@inlong.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org