提交 369ab096 编写于 作者: Y YunaiV

2018_12_16_精尽 Dubbo 源码解析 —— NIO 服务器(六)之 Netty4 实现.md

上级 8a92f003
...@@ -23,8 +23,14 @@ import com.alibaba.dubbo.remoting.RemotingException; ...@@ -23,8 +23,14 @@ import com.alibaba.dubbo.remoting.RemotingException;
import com.alibaba.dubbo.remoting.Server; import com.alibaba.dubbo.remoting.Server;
import com.alibaba.dubbo.remoting.Transporter; import com.alibaba.dubbo.remoting.Transporter;
/**
* 基于 Netty4 的网络传输实现类
*/
public class NettyTransporter implements Transporter { public class NettyTransporter implements Transporter {
/**
* 拓展名
*/
public static final String NAME = "netty4"; public static final String NAME = "netty4";
public Server bind(URL url, ChannelHandler listener) throws RemotingException { public Server bind(URL url, ChannelHandler listener) throws RemotingException {
...@@ -35,4 +41,4 @@ public class NettyTransporter implements Transporter { ...@@ -35,4 +41,4 @@ public class NettyTransporter implements Transporter {
return new NettyClient(url, listener); return new NettyClient(url, listener);
} }
} }
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册