Skip to content

Commit

Permalink
fix: increase max size of pact output buffer
Browse files Browse the repository at this point in the history
  • Loading branch information
cltatman authored and mefellows committed Aug 7, 2020
1 parent fd63b63 commit 0702b90
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions dsl/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,22 +193,25 @@ func (p *PactClient) VerifyProvider(request types.VerifyRequest) ([]types.Provid
stdOutScanner := bufio.NewScanner(stdOutPipe)
go func() {
wg.Add(1)
defer wg.Done()
stdOutBuf := make([]byte, bufio.MaxScanTokenSize)
stdOutScanner.Buffer(stdOutBuf, 64*1024*1024)

for stdOutScanner.Scan() {
verifications = append(verifications, stdOutScanner.Text())
}

wg.Done()
}()

// Scrape errors
stdErrScanner := bufio.NewScanner(stdErrPipe)
go func() {
wg.Add(1)
defer wg.Done()
for stdErrScanner.Scan() {
stdErr.WriteString(fmt.Sprintf("%s\n", stdErrScanner.Text()))
}

wg.Done()
}()

err = cmd.Start()
Expand Down

0 comments on commit 0702b90

Please sign in to comment.