- Overview
- Getting started
- How To...
- User Guide
- Migration
-
Reference
-
Steps
- addItem
- addToInt
- addToSharedCounter
- awaitAllResponses
- awaitDelay
- awaitInt
- awaitVar
- breakIfFinished
- breakSequence
- clearHttpCache
- conditional
- fail
- foreach
- getIndex
- getItem
- getSharedCounter
- getSize
- hotrodRequest
- httpRequest
- json
- log
- loop
- markRequestInvalid
- newSequence
- noop
- publishAgentData
- publishGlobalCounters
- pullSharedMap
- pushSharedMap
- randomCsvRow
- randomFile
- randomInt
- randomItem
- randomUUID
- readAgentData
- removeItem
- restartSequence
- scheduleDelay
- set
- setInt
- setItem
- setSharedCounter
- stop
- stopwatch
- stringToInt
- template
- thinkTime
- timestamp
- unset
-
Processors
- addItem
- addToInt
- addToSharedCounter
- array
- clearHttpCache
- closeConnection
- collection
- conditional
- count
- fail
- getIndex
- getItem
- getSharedCounter
- getSize
- gzipInflator
- json
- log
- logInvalid
- markRequestInvalid
- newSequence
- parseHtml
- publishAgentData
- publishGlobalCounters
- queue
- readAgentData
- removeItem
- restartSequence
- set
- setInt
- setItem
- setSharedCounter
- store
- storeInt
- stringToInt
- unset
- Actions
-
Steps
- Custom extensions
- Controller API
- Architecture
- Release notes
randomFile
Reads bytes from a randomly chosen file into a variable.
Two formats are supported:
Example 1 - without weights:
toVar: myVar
files:
- /path/to/file1.txt
- file2_relative_to_benchmark.txt
Example 2 - with weights (the second file will be returned twice as often):
toVar: myVar
files:
/path/to/file1.txt: 1
file2_relative_to_benchmark.txt: 2
Property | Type | Description |
---|---|---|
filenameVar | String | Optional variable to store the filename of the random file. |
files | Builder | Potentially weighted list of files to choose from. |
toVar | String | Variable where the chosen byte array should be stored. |
files
Property | Type | Description |
---|---|---|
<any> | <list of strings> | Item as the key and weight (arbitrary floating-point number, defaults to 1.0) as the value. |
<list of strings> | <list of strings> | Item as the key and weight (arbitrary floating-point number, defaults to 1.0) as the value. |