Skip to content

Commit 4ab898d

Browse files
committed
fixed README
1 parent d816297 commit 4ab898d

File tree

2 files changed

+24
-11
lines changed

2 files changed

+24
-11
lines changed

README.md

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,28 @@ However I needed to do more complex and fundamental customization, such as addin
1313

1414
I would like to thank Peter Zaitsev, Alexy Kopytov and contributors for inventing great tool [sysbench](https://github.com/akopytov/sysbench).
1515

16-
## Install
16+
## Usage
17+
18+
### Install
1719

1820
```
1921
go install github.com/samitani/go-sysbench/cmd/go-sysbench@latest
2022
```
2123

22-
## Usage
23-
24-
### General Syntax
24+
### Run benchmark
25+
1. Create a database to run benchmark.
26+
```
27+
mysql> CREATE DATABASE sbtest;
28+
```
29+
2. Execute prepare command to create tables and records.
30+
```
31+
go-sysbench --tables=1 --mysql-port=3570 --mysql-user=app --mysql-password=Password --time=360 --threads=5 --table_size=10000 --report-interval=1 --histogram=on oltp_read_write prepare
32+
```
33+
3. Run benchmark
34+
In this example, It will run the benchmark for 360 seconds with 5 threads.
35+
```
36+
go-sysbench --tables=1 --mysql-port=3570 --mysql-user=app --mysql-password=Password --time=360 --threads=5 --table_size=10000 --report-interval=1 --histogram=on oltp_read_write run
37+
```
2538

2639
### Options
2740

cmd/go-sysbench/main.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,20 @@ package main
33
// TODO
44
// 1. SpannerのBIT_REVERSEを試す
55

6-
// 12. thread fairness の計算
6+
// 10. thread fairness の計算
77

88
// 20. PreparedStatement の実装
99

10-
// 41. 空振りクエリはotherにカウントする
10+
// 30. --table-size のサポート (--table_size の alias)
11+
12+
// 40. 空振りクエリはotherにカウントする
1113

1214
// 50. README に 日本語を書く
13-
// 51. README に 実行方法について書く
14-
// 52. README に 性能差分について書く
15+
// 51. README に 性能差分について書く
1516

16-
// 60. フラグの順番の制約解除
17+
// 61. ignore-error 数のレポート
18+
// 62. --mysql-ignore-errors の場合 others にカウントする
1719

18-
// 71. ignore-error 数のレポート
19-
// 72. --mysql-ignore-errors の場合 others にカウントする
2020

2121
import (
2222
"log"

0 commit comments

Comments
 (0)