Reduce system call overhead reading from connections

This commit is contained in:
Matt Joiner 2017-09-21 19:29:56 +10:00
parent 3879364536
commit 326f60b319
1 changed files with 1 additions and 1 deletions

View File

@ -720,7 +720,7 @@ func (c *connection) mainReadLoop() error {
cl := t.cl cl := t.cl
decoder := pp.Decoder{ decoder := pp.Decoder{
R: bufio.NewReader(c.r), R: bufio.NewReaderSize(c.r, 1<<17),
MaxLength: 256 * 1024, MaxLength: 256 * 1024,
Pool: t.chunkPool, Pool: t.chunkPool,
} }