From b34e84ac87fc6528c4a4aecd3b1a327dbf3f01a5 Mon Sep 17 00:00:00 2001 From: George Schwarzman Date: Tue, 23 Feb 2021 21:38:13 +0200 Subject: [PATCH 1/2] Added pause option for delayed read test --- s3bench.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/s3bench.go b/s3bench.go index 76af88f..07c5aa1 100644 --- a/s3bench.go +++ b/s3bench.go @@ -38,6 +38,7 @@ func main() { numClients := flag.Int("numClients", 40, "number of concurrent clients") numSamples := flag.Int("numSamples", 200, "total number of requests to send") skipCleanup := flag.Bool("skipCleanup", false, "skip deleting objects created by this tool at the end of the run") + pause := flag.Bool("pause", false, "pause before starting read stage") verbose := flag.Bool("verbose", false, "print verbose per thread status") flag.Parse() @@ -92,6 +93,13 @@ func main() { writeResult := params.Run(opWrite) fmt.Println() + // Pause after write test and before read test + if *pause { + fmt.Printf("Press enter to start read test...\n") + fmt.Scanln() + fmt.Println() + } + fmt.Printf("Running %s test...\n", opRead) readResult := params.Run(opRead) fmt.Println() From 57f5c3fa4b392742e0d206f6e9226c1144b41657 Mon Sep 17 00:00:00 2001 From: George Schwarzman Date: Wed, 24 Feb 2021 16:12:52 +0200 Subject: [PATCH 2/2] Fixed 'verbose' parameter in parameters output --- s3bench.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/s3bench.go b/s3bench.go index 07c5aa1..712d935 100644 --- a/s3bench.go +++ b/s3bench.go @@ -263,7 +263,7 @@ func (params Params) String() string { output += fmt.Sprintf("objectSize: %0.4f MB\n", float64(params.objectSize)/(1024*1024)) output += fmt.Sprintf("numClients: %d\n", params.numClients) output += fmt.Sprintf("numSamples: %d\n", params.numSamples) - output += fmt.Sprintf("verbose: %d\n", params.verbose) + output += fmt.Sprintf("verbose: %t\n", params.verbose) return output }