Skip to content
Myr

Increase read buffer size to 64KB

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Junegunn Choi · committed by Junegunn Choi · parent c4c9214 · Browse files · 2 files+3 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+3 added−2 removed

  • other:+3 added−2 removed

2 files+3 added−2 removed

modified:src/constants.go+2 added-1 removed
13 unmodified lines
14 coordinatorDelayMax time.Duration = 100 * time.Millisecond15 coordinatorDelayStep time.Duration = 10 * time.Millisecond1617 // Reader18 defaultCommand = `find . -path '*/\.*' -prune -o -type f -print -o -type l -print 2> /dev/null | sed s/^..//`18 defaultCommand = `find . -path '*/\.*' -prune -o -type f -print -o -type l -print 2> /dev/null | sed s/^..//`19 readerBufferSize = 64 * 10242021 // Terminal22 initialDelay = 20 * time.Millisecond23 initialDelayTac = 100 * time.Millisecond
38 unmodified lines
modified:src/reader.go+1 added-1 removed
32 unmodified lines
33 delim := byte('\n')34 if r.delimNil {35 delim = '\000'36 }37 reader := bufio.NewReader(src)37 reader := bufio.NewReaderSize(src, readerBufferSize)38 for {39 // ReadBytes returns err != nil if and only if the returned data does not40 // end in delim.41 bytea, err := reader.ReadBytes(delim)
31 unmodified lines