Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
workload/tpcc: fix race condition in scattering tables
When iterating over the names of tables to scatter, we were sharing the loop variable between the goroutines, which is racy and caused a test failure due to reading a garbage string value for the table name. In general, this function is not going to scatter each table exactly once. This PR fixes it by making a copy of the variable per loop iteration. Release note (bug fix): Fixed a race condition in the `tpcc` workload with the `--scatter` flag where tables could be scattered multiple times or not at all.
- Loading branch information