-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
01fed44
commit c8d9d7b
Showing
1 changed file
with
51 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# tsubakuro-examples - example client programs using tsubakuro for tsurugidb | ||
|
||
## Requirements | ||
|
||
* Java `>= 11` | ||
|
||
* dependent modules: | ||
* [Tsubakuro](https://github.com/project-tsurugi/tsubakuro) | ||
|
||
|
||
## tpc-c | ||
### setup | ||
``` | ||
git clone [email protected]:project-tsurugi/tsubakuro-examples.git | ||
pushd tsubakuro-examples/modules/tpccLoader | ||
../../gradlew build | ||
popd | ||
pushd | ||
cd tsubakuro-examples/modules/tpcc | ||
../../gradlew build | ||
popd | ||
``` | ||
|
||
### table初期データ作成 | ||
https://github.com/project-tsurugi/jogasaki-benchmarks/tree/master/tpc-c-datagen/README.md 参照 | ||
|
||
### benchmark実行 | ||
benchmark実行は、tsurugidbを起動し、table初期データをloadした後にクライアントプログラムを実行する。 | ||
|
||
#### tsurugidb起動 | ||
``` | ||
tgctl start | ||
``` | ||
|
||
#### table初期データload | ||
``` | ||
cd tsubakuro-examples | ||
./gradlew runTpccLoader --args="-w ${warehouse} -d ${directory}" | ||
``` | ||
|
||
\${warehouse}はwarehouse数、\${directory}はtable初期データを格納したディレクトリ。table初期データ作成時に大きなwarehouseでデータ作成していても、\${warehouse}で指定したwarehouse数分のデータだけを読み込む。 | ||
|
||
|
||
#### クライアントプログラム実行 | ||
``` | ||
cd tsubakuro-examples | ||
./gradlew runTpcc --args="${threads} ${duration}" | ||
``` | ||
|
||
\${threads}はクライアントスレッド数、\${duration}はベンチマーク実行時間(単位は秒)。各々のデフォルト値は、\${threads}が8、\${duration}が30。なお、warehouse数を指定する必要はない(ベンチマーク実行に先立ってWAREHOUSE表をSELECT COUNTして得ている)。 |