Skip to content

Commit

Permalink
Merge pull request #504 from vitessio/less-shards-for-unsharded
Browse files Browse the repository at this point in the history
Unsharded benchmarks with two vttablets and a smaller TPCC scale
  • Loading branch information
frouioui authored Jan 30, 2024
2 parents b111d99 + 0729e77 commit 7cf76ed
Show file tree
Hide file tree
Showing 6 changed files with 39 additions and 13 deletions.
28 changes: 27 additions & 1 deletion ansible/macrobench_unsharded_inventory.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,13 @@ all:
vttablet_max_goproc: 42
hosts:
DEVICE_IP_0:
tablets:
# all_tablets is a list of all the possible tablets in the cluster
# this list is used to properly clean up the machine from all tablets
# if the previous benchmark was a sharded cluster and it had failed
# and was not able to clean up correctly, using the unsharded list of
# tablets will results in a not complete clean up as we would only remove
# two tablets instead of four.
all_tablets:
- id: 1001
keyspace: main
shard: 0
Expand Down Expand Up @@ -102,3 +108,23 @@ all:
grpc_port: 17022
mysql_port: 18022
mysqld_exporter_port: 9107
# tablets is the list of tablets to use for this unsharded benchmark
tablets:
- id: 1001
keyspace: main
shard: 0
pool_size: 500
transaction_cap: 2000
port: 16011
grpc_port: 17011
mysql_port: 18011
mysqld_exporter_port: 9104
- id: 1002
keyspace: main
shard: 0
pool_size: 500
transaction_cap: 2000
port: 16012
grpc_port: 17012
mysql_port: 18012
mysqld_exporter_port: 9105
2 changes: 1 addition & 1 deletion ansible/roles/vttablet/tasks/clean.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

- name: clean all vttablet
include_tasks: clean_one.yml
loop: '{{ tablets }}'
loop: '{{ all_tablets }}'
loop_control:
loop_var: tablet

Expand Down
2 changes: 1 addition & 1 deletion config/benchmarks/tpcc_fk.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ macrobench_all_db-driver: mysql
macrobench_all_luajit-cmd: "off"
macrobench_all_threads: 42
macrobench_all_tables: 1
macrobench_all_scale: 100
macrobench_all_scale: 50
macrobench_all_rand-type: uniform
macrobench_all_rand-seed: 1
macrobench_all_use_fk: 1
Expand Down
2 changes: 1 addition & 1 deletion config/benchmarks/tpcc_fk_unmanaged.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ macrobench_all_db-driver: mysql
macrobench_all_luajit-cmd: "off"
macrobench_all_threads: 42
macrobench_all_tables: 1
macrobench_all_scale: 100
macrobench_all_scale: 50
macrobench_all_rand-type: uniform
macrobench_all_rand-seed: 1
macrobench_all_use_fk: 1
Expand Down
2 changes: 1 addition & 1 deletion config/benchmarks/tpcc_unsharded.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ macrobench_all_db-driver: mysql
macrobench_all_luajit-cmd: "off"
macrobench_all_threads: 42
macrobench_all_tables: 1
macrobench_all_scale: 100
macrobench_all_scale: 50
macrobench_all_rand-type: uniform
macrobench_all_rand-seed: 1
macrobench_all_use_fk: 0
Expand Down
16 changes: 8 additions & 8 deletions go/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,14 +174,14 @@ func (s *Server) Init() error {
}

s.benchmarkConfig = map[string]benchmarkConfig{
"micro": {file: path.Join(s.benchmarkConfigPath, "micro.yaml"), v: viper.New(), skip: true},
"oltp": {file: path.Join(s.benchmarkConfigPath, "oltp.yaml"), v: viper.New()},
"oltp-set": {file: path.Join(s.benchmarkConfigPath, "oltp-set.yaml"), v: viper.New()},
"oltp-readonly": {file: path.Join(s.benchmarkConfigPath, "oltp-readonly.yaml"), v: viper.New()},

// TODO: oltp-readonly-olap benchmarks are skipped for now as they fail very often due to
// MySQL connections being dropped. This issue will be investigated soon.
"oltp-readonly-olap": {file: path.Join(s.benchmarkConfigPath, "olap-readonly.yaml"), v: viper.New(), skip: true},
// "micro": {file: path.Join(s.benchmarkConfigPath, "micro.yaml"), v: viper.New(), skip: true},
// "oltp": {file: path.Join(s.benchmarkConfigPath, "oltp.yaml"), v: viper.New()},
// "oltp-set": {file: path.Join(s.benchmarkConfigPath, "oltp-set.yaml"), v: viper.New()},
// "oltp-readonly": {file: path.Join(s.benchmarkConfigPath, "oltp-readonly.yaml"), v: viper.New()},
//
// // TODO: oltp-readonly-olap benchmarks are skipped for now as they fail very often due to
// // MySQL connections being dropped. This issue will be investigated soon.
// "oltp-readonly-olap": {file: path.Join(s.benchmarkConfigPath, "olap-readonly.yaml"), v: viper.New(), skip: true},

"tpcc": {file: path.Join(s.benchmarkConfigPath, "tpcc.yaml"), v: viper.New()},
"tpcc_unsharded": {file: path.Join(s.benchmarkConfigPath, "tpcc_unsharded.yaml"), v: viper.New()},
Expand Down

0 comments on commit 7cf76ed

Please sign in to comment.