Skip to content

Commit

Permalink
Merge #104470
Browse files Browse the repository at this point in the history
104470: roachtest: disable scheduled backups during tpccbench r=dt a=stevendanna

We originally enabled the scheduled backups for tpccbench by reasoning that backups were like any other background task. These tests don't disable GC or auto stats jobs, why should they disable backups?

Here, we reverse that decision.

The tpccbench tests are designed to find the maximum tpcc warehouse count that a cluster can reach. As such, they push the cluster to high resource utilisation, leaving little overhead for backups.

While it is true that a user would also need to take backups, they have the option of scheduling backups for times at which they aren't at peak traffic.

Further, the tpccbench tests run tpccbench multiple times in an attempt to search for the max warehouse count. Making it a bit harder to understand the impact of the every-15-minute schedule on the results.

Epic: none

Release note: None

Co-authored-by: Steven Danna <[email protected]>
  • Loading branch information
craig[bot] and stevendanna committed Jun 8, 2023
2 parents 5c33b74 + 12b32a5 commit 46cc1a6
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion pkg/cmd/roachtest/tests/tpcc.go
Original file line number Diff line number Diff line change
Expand Up @@ -828,6 +828,13 @@ func registerTPCC(r registry.Registry) {
LoadWarehouses: 1000,
EstimatedMax: gceOrAws(cloud, 750, 900),
})
registerTPCCBenchSpec(r, tpccBenchSpec{
Nodes: 3,
CPUs: 4,
EnableDefaultScheduledBackup: true,
LoadWarehouses: 1000,
EstimatedMax: gceOrAws(cloud, 750, 900),
})
registerTPCCBenchSpec(r, tpccBenchSpec{
Nodes: 3,
CPUs: 16,
Expand Down Expand Up @@ -1022,7 +1029,8 @@ type tpccBenchSpec struct {
// Encryption-At-Rest / EAR).
EncryptionEnabled bool
// ExpirationLeases enables use of expiration-based leases.
ExpirationLeases bool
ExpirationLeases bool
EnableDefaultScheduledBackup bool
}

// partitions returns the number of partitions specified to the load generator.
Expand All @@ -1042,6 +1050,7 @@ func (s tpccBenchSpec) partitions() int {
// startOpts returns any extra start options that the spec requires.
func (s tpccBenchSpec) startOpts() (option.StartOpts, install.ClusterSettings) {
startOpts := option.DefaultStartOpts()
startOpts.RoachprodOpts.ScheduleBackups = s.EnableDefaultScheduledBackup
settings := install.MakeClusterSettings()
// Facilitate diagnosing out-of-memory conditions in tpccbench runs.
// See https://github.com/cockroachdb/cockroach/issues/75071.
Expand All @@ -1065,6 +1074,9 @@ func registerTPCCBenchSpec(r registry.Registry, b tpccBenchSpec) {
if b.Chaos {
nameParts = append(nameParts, "chaos")
}
if b.EnableDefaultScheduledBackup {
nameParts = append(nameParts, "backups=true")
}

opts := []spec.Option{spec.CPU(b.CPUs)}
if b.HighMem {
Expand Down

0 comments on commit 46cc1a6

Please sign in to comment.