}
@Override
protected void channelRead0(ChannelHandlerContext ctx, String msg) throws Exception {
try {
SocketRequest request = new DefaultSocketRequest(msg);
this.monitor.onMessageArrived(request);
SocketResponse response = new DefaultSocketResponse();
handleSession(new SessionContext(request, response));
this.monitor.onMessageLeave(response);
ctx.write(response.getContent());