chenzhangyi commented on issue #2120: URL: https://github.com/apache/brpc/issues/2120#issuecomment-1438072650
> > 协议解析的时候需要的应该只是一小部分body吧,例如brpc的协议其实只需要前12个字节就可以确认了,后续的内存可以先申请,然后把前12个字节的数据重新set一下就可以了吧,不知道这个理解是否正确? > > 不是把前12个字节的数据重新set一下,是要把提前读到的部分body先吐出来,然后写入一段连续的内存,再用这段连续内存进行后续的写入 @wwbmmm 如果考虑做一些特殊处理的话,是可以放弃多协议的支持去实现这个模式的? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
