5.netty执行流程分析以及重要组件介绍 - mrwang1992/netty_student GitHub Wiki

netty的作用场景

  • RPC 远程连接库
  • 长连接服务器
  • http服务器.jetty 之类的(但是规范不一样 不按照 Servlet 规范)

netty 做http服务(tag为 class_5 的代码就是课程结束后的结果)

  • helloworld程序 ( wang.huaiting.netty.firstexample )

netty 执行基本流程

  • 定义线程组
  • 启动bootstrap 里面包含 两个线程组 , 服务器启动时关联相关处理器,我们可以添加自己的处理器进行处理

netty 组件

channle

  • 通道

handle

  • 处理器

pipline 由多个 channle + handle 组成

netty 启动