/* *
* data triggered when
*/
@ Override
Protected void channelRead0 (ChannelHandlerContext CTX, TextWebSocketFrame MSG) throws the Exception {
}
/* *
* connection is established after the first executive
*/
@ Override
Public void handlerAdded ChannelHandlerContext (CTX) throws the Exception {
CTX. Channel (.) writeAndFlush (new TextWebSocketFrame (" hello world "));
}
Front-end receive less than data, send in function channelRead0 can receive this is going on
CodePudding user response:
Your channelRead0 the codeCodePudding user response: