Class | RFuzz::Session |
In: |
lib/rfuzz/session.rb
|
Parent: | Object |
Creates a small light DSL for running RFuzz sessions against a web server. It configures a basic client and randomizer that you then use to conduct sessions and record statistics about the activity.
counts | [RW] | |
runs | [RW] | |
tracking | [RW] |
Sets up a session that you then operate by calling Session#run. Most of the functions do not work unless they are inside a Session#run call.
Available options are:
You can then pass any options you need to pass to the created RFuzz::HttpClient.
Used inside Session#run to wrap an attempted request or potentially failing action and then count the exceptions thrown.
Takes the counts for all the runs and produces an array suitable for CSV output. Use Session#counts to access the counts directly.
Begin a run of count length wher a block is run once and statistics are collected from the client passed to the block. When calls you can pass in the following options:
Once you call run, the block you pass it is given an HttpClient and a RandomGenerator. Each run will reset the HttpClient so you can pretend it is brand new.
Takes the samples for all runs and returns an array suitable for passing to CSV or some other table output. If you want to access the runs directly then just use the Session#runs attribute.
Called inside a run to collect a stat you want with the given count. The stat should be a string or symbol, and count should be a number (or float).