《netty源码》之-ChannelHandlerContext.write
ctx.write方法
->
调用ctx.prev,找到outbound的下一个context
调用 context的 write方法,转到 handler 的 write 方法
绑定该context的handler 是 encoder
->
encoder 的write 方法包含两个操作
encode
调用 ctx.write
->
调用ctx.prev,找到outbound的下一个context
绑定该context的 handler 是headContext类型
->
headContext.write 方法 最终调用 unsafe.write