|
ravel
Deterministic simulation testing for C++. Seed a bug, replay it exact.
|
Injectable disk behavior. More...
#include <disk.hpp>
Public Attributes | |
| std::uint64_t | capacity_bytes = 1ULL << 30 |
| Total bytes across all files. | |
| VirtualClock::Tick | latency_min = 0 |
| Each operation takes a uniformly random time in [min, max]. | |
| VirtualClock::Tick | latency_max = 0 |
| The upper end of the range above. | |
| double | write_error_probability = 0.0 |
| In [0, 1]. Writes, renames and removes fail with IoError, changing nothing. | |
| double | sync_error_probability = 0.0 |
| In [0, 1]. | |
Injectable disk behavior.
Every decision is drawn from the Simulation's VirtualRng, so it replays identically for a given seed.
| std::uint64_t ravel::DiskFaultSpec::capacity_bytes = 1ULL << 30 |
Total bytes across all files.
The default (1 GiB) only guards against a stray offset asking for absurd amounts of memory.
| double ravel::DiskFaultSpec::sync_error_probability = 0.0 |
In [0, 1].
Syncing a file fails with IoError and drops the data it should have flushed; syncing a directory fails with IoError and changes nothing.