概要
ディレクトリ構成
├── LICENSE ├── bin │ └── gatlingやrecorderの実行ファイルが格納されている。 ├── conf │ └── 設定ファイル全般 ├── lib │ └── gatling自身が利用するjarファイルなど ├── results └── テスト結果のログ、レポートの生成先 └── user-files └── resources │ └── search.csv └── simulations └── 実行するシュミレーション用のスクリプトを格納する場所
setUp(
scn.inject(
nothingFor(4 seconds), // 1
atOnceUsers(10), // 2
rampUsers(10) during (5 seconds), // 3
constantUsersPerSec(20) during (15 seconds), // 4
constantUsersPerSec(20) during (15 seconds) randomized, // 5
rampUsersPerSec(10) to 20 during (10 minutes), // 6
rampUsersPerSec(10) to 20 during (10 minutes) randomized, // 7
heavisideUsers(1000) during (20 seconds) // 8
).protocols(httpProtocol)
)
① 特定の時間一時停止
② 指定した数のユーザー数で同時アクセス
③ 指定した数のユーザーに到達するまで線形に増加
④ 一定の割合でユーザー数を増加させる
⑤ Injects users at a constant rate, defined in users per second, during a given duration. Users will be injected at randomized intervals.
⑥ Injects users from starting rate to target rate, defined in users per second, during a given duration. Users will be injected at regular intervals.
⑦ Injects users from starting rate to target rate, defined in users per second, during a given duration. Users will be injected at randomized intervals.
⑧ Injects a given number of users following a smooth approximation of the heaviside step function stretched to a given duration.