imay commented on a change in pull request #2603: Add nio support for mysql 
protocol implementation
URL: https://github.com/apache/incubator-doris/pull/2603#discussion_r361663840
 
 

 ##########
 File path: fe/src/main/java/org/apache/doris/mysql/MysqlChannel.java
 ##########
 @@ -33,25 +33,34 @@
 public class MysqlChannel {
     // max length which one MySQL physical can hold, if one logical packet is 
bigger than this,
     // one packet will split to many packets
-    private static final int MAX_PHYSICAL_PACKET_LENGTH = 0xffffff - 1;
+    protected static final int MAX_PHYSICAL_PACKET_LENGTH = 0xffffff - 1;
     // MySQL packet header length
-    private static final int PACKET_HEADER_LEN = 4;
+    protected static final int PACKET_HEADER_LEN = 4;
     // logger for this class
-    private static final Logger LOG = LogManager.getLogger(MysqlChannel.class);
+    protected static final Logger LOG = 
LogManager.getLogger(MysqlChannel.class);
     // next sequence id to receive or send
-    private int sequenceId;
+    protected int sequenceId;
     // channel connected with client
-    private SocketChannel channel;
+    protected SocketChannel channel;
     // used to receive/send header, avoiding new this many time.
-    private ByteBuffer headerByteBuffer = 
ByteBuffer.allocate(PACKET_HEADER_LEN);
+    protected ByteBuffer headerByteBuffer = 
ByteBuffer.allocate(PACKET_HEADER_LEN);
     // default packet byte buffer for most packet
-    private ByteBuffer defaultBuffer = ByteBuffer.allocate(16 * 1024);
-    private ByteBuffer sendBuffer;
+    protected ByteBuffer defaultBuffer = ByteBuffer.allocate(16 * 1024);
+    protected ByteBuffer sendBuffer;
     // for log and show
-    private String remoteHostPortString;
-    private String remoteIp;
-    private boolean isSend;
+    protected String remoteHostPortString;
+    protected String remoteIp;
+    protected boolean isSend;
 
+
+    public MysqlChannel() {
 
 Review comment:
   Is protected enough?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to