Stage File
Stage files are YAML format. This is a quick reference with fake but syntactically valid values:
stage:
disable: false
name: "read-only"
qps: "1,000"
runtime: "60s"
tps: "500"
compute:
disable-local: false
instances: 0
mysql:
# Override mysql from _all.yaml
params:
# Override params from _all.yaml
stats:
# Override stats from _all.yaml
trx:
- name: "foo" ##########
file: "trx/foo.sql" #
data: #
d: #
generator: "int" #
#
workload: #
- trx: ["foo"] #########
clients: 1
db: ""
iter: "0"
iter-clients: "0"
iter-exec-group: "0"
qps: "0"
qps-clients: "0"
qps-exec-group: "0"
runtime: "0s"
tps: "0"
tps-clients: "0"
tps-exec-group: "0"
A stage file starts with a top-level stage:
declaration.
- Default: false
- Value: boolean
Disable the stage entirely if true.
- Default: base file name
- Value: string
The stage name.
- Default: 0 (unlimited)
- Value: string-int ≥ 0
Queries per second (QPS) limit for all clients, all execution groups.
- Default: 0 (unlimited)
- Value: time duration ≥ 0
How long to run the stage. If zero and there are no data limits, use CTRL-C to stop the stage and report stats.
- Default: 0 (unlimited)
- Value: string-int ≥ 0
Transaction per second (TPS) limit for all clients, all execution groups.
- Default: false
- Value: boolean
If true, the local Finch instances does not count as 1 compute.
- Default: 1
- Value: string-int ≥ 0
The number of compute instances that Finch requires to run the benchmark.
See mysql
in all.yaml.
See params
in all.yaml.
See stats
in all.yaml.
The trx
section is a required list of Finch trx files to load.
stage:
trx:
- file: trx/A.sql
name: foo
- file: trx/B.sql
# name defaults to B.sql
- Default: (none; must be set explicitly)
- Value: file name
Sets one Finch trx file to load. Paths are relative to the directory of the stage file.
- Default: (none; must be set explicitly)
- Value: map keyed on data key name without
@
prefix
Every data key in a trx file must be defined in the stage file.
stage:
trx:
- file: foo.sql # uses @d
data:
d: # key for @d
generator: "int" # __REQUIRED__
scope: "trx" # optional
params: # generator-specific
max: "10,000" #
Only generator
is required, but you usually need to specify params
too.
Only @d (“d” in the stage file) is shown here, but every data key in a trx file must be defined in thedata
map.
- Default: “n”
- Value: “n” or “s”
Indicates column type: “n” for a numeric value, or “s” for a string (quoted) value.
- Default: (none; must be set explicitly)
- Type: name of data generator
Name of the data generator to use for the data key.
- Default: (none)
- Value: key-value map of strings
Generator-specific params. These are optional but usually needed. See Data / Generators
- Default: statement
- Value: "" or “statement”, “trx”, “client”
Scope of data generator. If not specified (empty string), the default is “statement”. See Data / Scope.
- Default: Base file name
- Value: any string
Set trx name used in workload.trx
list.
The workload
section declares the workload that references the trx
section.
- Default: 1
- Value: string-int ≥ 1
Number of clients to run in client group.
- Default: (none)
- Value: database name
Deafult client group database.
See Operate / MySQL / Default Database
Makes clients in client group execute USE db
on prepare.
- Default: 0 (unlimited)
- Value: string-int ≥ 1
Maximum number of iterations to execute per client, client group, or execution group (respectively).
- Default: 0 (unlimited)
- Value: string-int ≥ 1
Maximum rate of queries per second (QPS) per client, client group, or execution group (respectively).
- Default: 0 (forever)
- Value: string-int ≥ 1
Runtime limit
- Default: 0 (unlimited)
- Value: string-int ≥ 1
Maximum rate of transaction per second (TPS) per client, client group, or execution group (respectively).
- Default: none or auto
- Value: list of
trx.name
Trx assigned to all clients to execute.