From 2275eba91f0a588be867960a09a9af59b2e0ed92 Mon Sep 17 00:00:00 2001 From: coffeegoddd Date: Wed, 14 Feb 2024 15:18:25 -0800 Subject: [PATCH] /go/performance/utils/benchmark_runner/{sysbench,tpcc}.go: fix output already set error --- go/performance/utils/benchmark_runner/sysbench.go | 2 +- go/performance/utils/benchmark_runner/tpcc.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/go/performance/utils/benchmark_runner/sysbench.go b/go/performance/utils/benchmark_runner/sysbench.go index 71ff223053..2b8636dffc 100644 --- a/go/performance/utils/benchmark_runner/sysbench.go +++ b/go/performance/utils/benchmark_runner/sysbench.go @@ -134,7 +134,7 @@ func (t *sysbenchTesterImpl) run(ctx context.Context) (*Result, error) { } func (t *sysbenchTesterImpl) cleanup(ctx context.Context) error { - cmd := ExecCommand(ctx, sysbenchCommand, t.test.GetCleanupArgs(t.serverConfig)...) + cmd := exec.CommandContext(ctx, sysbenchCommand, t.test.GetCleanupArgs(t.serverConfig)...) if t.test.GetFromScript() { lp := filepath.Join(t.config.GetScriptDir(), luaPath) cmd.Env = os.Environ() diff --git a/go/performance/utils/benchmark_runner/tpcc.go b/go/performance/utils/benchmark_runner/tpcc.go index e8dc59c33f..be265e6b56 100644 --- a/go/performance/utils/benchmark_runner/tpcc.go +++ b/go/performance/utils/benchmark_runner/tpcc.go @@ -53,7 +53,7 @@ func (t *tpccTesterImpl) outputToResult(output []byte) (*Result, error) { func (t *tpccTesterImpl) prepare(ctx context.Context) error { args := t.test.GetPrepareArgs(t.serverConfig) - cmd := ExecCommand(ctx, t.tpccCommand, args...) + cmd := exec.CommandContext(ctx, t.tpccCommand, args...) cmd = t.updateCmdEnv(cmd) out, err := cmd.Output() if err != nil { @@ -65,7 +65,7 @@ func (t *tpccTesterImpl) prepare(ctx context.Context) error { func (t *tpccTesterImpl) run(ctx context.Context) (*Result, error) { args := t.test.GetRunArgs(t.serverConfig) - cmd := ExecCommand(ctx, t.tpccCommand, args...) + cmd := exec.CommandContext(ctx, t.tpccCommand, args...) cmd = t.updateCmdEnv(cmd) out, err := cmd.Output() @@ -90,7 +90,7 @@ func (t *tpccTesterImpl) run(ctx context.Context) (*Result, error) { func (t *tpccTesterImpl) cleanup(ctx context.Context) error { args := t.test.GetCleanupArgs(t.serverConfig) - cmd := ExecCommand(ctx, t.tpccCommand, args...) + cmd := exec.CommandContext(ctx, t.tpccCommand, args...) cmd = t.updateCmdEnv(cmd) err := cmd.Run() if err != nil {