项目运行中出现org.apache.mina.filter.codec.RecoverableProtocolDecoderException: Line is too long,
是因为mina2默认的行解码器长度太小,为1024,
修改如下
TextLineCodecFactory textLineCodec=new TextLineCodecFactory(Charset.forName("UTF-8"));
textLineCodec.setDecoderMaxLineLength(20480);
textLineCodec.setEncoderMaxLineLength(20480);