From bb2a3ea8d856668820073411403633008df8a685 Mon Sep 17 00:00:00 2001 From: Anthony Romano Date: Tue, 31 May 2016 00:37:54 -0700 Subject: [PATCH] benchmark: respect stm isolation mode flag --- tools/benchmark/cmd/stm.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/benchmark/cmd/stm.go b/tools/benchmark/cmd/stm.go index 4fde69319..1b1d97ad3 100644 --- a/tools/benchmark/cmd/stm.go +++ b/tools/benchmark/cmd/stm.go @@ -78,7 +78,7 @@ func stmFunc(cmd *cobra.Command, args []string) { switch stmIsolation { case "r": mkSTM = v3sync.NewSTMRepeatable - case "l": + case "s": mkSTM = v3sync.NewSTMSerializable default: fmt.Fprintln(os.Stderr, cmd.Usage()) @@ -141,8 +141,7 @@ func doSTM(ctx context.Context, client *v3.Client, requests <-chan stmApply) { for applyf := range requests { st := time.Now() - _, err := v3sync.NewSTMRepeatable(context.TODO(), client, applyf) - + _, err := mkSTM(context.TODO(), client, applyf) var errStr string if err != nil { errStr = err.Error()