Skip to content

Commit

Permalink
Merge branch 'complete' of github.com:ClSlaid/loadgen into complete
Browse files Browse the repository at this point in the history
  • Loading branch information
ClSlaid committed Aug 20, 2021
2 parents 578fef7 + 8ba13bb commit b47fe8a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions data/load_data.go
Expand Up @@ -98,6 +98,9 @@ func (c *LoadDataSuite) splitTableRegion(db *sql.DB, t *TableInfo, rows, regionR
return
}
regionNum := rows / regionRowNum
if regionNum <= 1 {
return
}
fmt.Printf("split %v regions for table %v\n", regionNum, t.DBTableName())

split := fmt.Sprintf("split table %v between (0) and (%v) regions %v;", t.DBTableName(), rows, regionNum)
Expand Down
4 changes: 2 additions & 2 deletions payload/basic_query.go
Expand Up @@ -162,8 +162,8 @@ func (c *basicQuerySuite) prepare() error {
return err
}
c.tblInfo = tblInfo
load := data.NewLoadDataSuite(c.cfg)
return load.Prepare(tblInfo, c.rows, c.rows/100000)
load := data.NewLoadDataSuit(c.cfg)
return load.Prepare(tblInfo, c.rows, 100000)
}

func (c *basicQuerySuite) Run() error {
Expand Down

0 comments on commit b47fe8a

Please sign in to comment.