code: private void handleTextWebSocketFrameInternal(TextWebSocketFrame frame, ChannelHandlerContext ctx) {
  		if (logger.isTraceEnabled()) {
  			logger.trace(String.format("%s received %s", ctx.channel(), frame.text()));
  		}
  
  		addTraceForFrame(frame, "text");
  		ctx.channel().write(new TextWebSocketFrame("Echo: " + frame.text()));
  	}
docs: simple echo implementation