Skip to content

Commit

Permalink
roachtest: switch the config order in tpchvec/perf
Browse files Browse the repository at this point in the history
Let's see whether it makes difference to occasional failures of
`tpchvec/perf` which are very hard to explain.

This commit also changes the workload command for `perf` config to run
only against node 1, thus, eliminating one possible source of
"randomness" for the failures.

Release note: None
  • Loading branch information
yuzefovich committed Jun 9, 2020
1 parent 6361e4c commit 33c1c7e
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions pkg/cmd/roachtest/tpchvec.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,6 @@ import (
"github.com/cockroachdb/errors"
)

const (
tpchVecNodeCount = 3
)

type crdbVersion int

const (
Expand Down Expand Up @@ -155,8 +151,8 @@ func (b tpchVecTestCaseBase) postTestRunHook(_ *test, _ *gosql.DB, _ crdbVersion

const (
tpchPerfTestNumRunsPerQuery = 3
tpchPerfTestVecOnConfigIdx = 0
tpchPerfTestVecOffConfigIdx = 1
tpchPerfTestVecOnConfigIdx = 1
tpchPerfTestVecOffConfigIdx = 0
)

type tpchVecPerfTest struct {
Expand All @@ -177,7 +173,7 @@ func newTpchVecPerfTest(disableStatsCreation bool) *tpchVecPerfTest {
func (p tpchVecPerfTest) vectorizeOptions() []bool {
// Since this is a performance test, each query should be run with both
// vectorize modes.
return []bool{true, false}
return []bool{false, true}
}

func (p tpchVecPerfTest) numRunsPerQuery() int {
Expand Down Expand Up @@ -372,8 +368,8 @@ func baseTestRun(
}
vectorizeSetting := vectorizeOptionToSetting(vectorize, version)
cmd := fmt.Sprintf("./workload run tpch --concurrency=1 --db=tpch "+
"--max-ops=%d --queries=%d --vectorize=%s {pgurl:1-%d}",
tc.numRunsPerQuery(), queryNum, vectorizeSetting, tpchVecNodeCount)
"--max-ops=%d --queries=%d --vectorize=%s {pgurl:1}",
tc.numRunsPerQuery(), queryNum, vectorizeSetting)
workloadOutput, err := c.RunWithBuffer(ctx, t.l, firstNode, cmd)
t.l.Printf("\n" + string(workloadOutput))
if err != nil {
Expand Down Expand Up @@ -480,6 +476,8 @@ func runTPCHVec(
testCase.postTestRunHook(t, conn, version)
}

const tpchVecNodeCount = 3

func registerTPCHVec(r *testRegistry) {
r.Add(testSpec{
Name: "tpchvec/perf",
Expand Down

0 comments on commit 33c1c7e

Please sign in to comment.