The Execution Engine
Welcome to the Execution Engine documentation!
Rumour uses a highly deterministic, graph-based execution engine that automatically infers the correct order of operations based on your variables and explicit dependencies.
1. Variable Resolution Hierarchy
Variables are at the core of Rumour. When a request is evaluated, Rumour resolves variables in the following strict priority order (from highest to lowest precedence):
- Vault Secrets: Secure credentials intercepted directly from the encrypted vault (
{{vault.*}}). - CLI Overrides: Variables explicitly passed during runtime via
-V/--var(-V key=value). - Request-Level Variables & Exported Dependencies: Variables defined within the request's
[variables]block or extracted from prerequisite dependencies. - Suite Variables: Variables defined within a
*.suite.tomlorchestration file. - CLI Custom Environment File: Variables loaded from an explicit overlay file (
-e custom.env.toml). - Hierarchical Environment Files: Scoped configuration from
*.env.tomlfiles (nearest directory >workspace.env.toml). - Collection Configuration: Baseline variables defined in collection config files (
*.config.toml,collection.toml).
Variable Substitution
You can inject variables into URLs, Headers, Bodies, or even assertions using the double-brace syntax: {{variable_name}}.
[request]
method = "POST"
url = "http://localhost:4000/api/{{version}}/users"
The {{random}} Keyword
Rumour provides a built-in {{random}} variable that automatically generates a unique alphanumeric string on every execution. This is perfect for creating unique emails, usernames, or transaction IDs.
execution_engine/requests/test_vars.toml
[body]
type = "json"
raw = '{"email": "user-{{random}}@swahira.io", "username": "user_{{random}}", "role": "user"}'
Output Trace
Notice how {{random}} interpolates into a unique UUID string during the execution trace:
$ rumour run ./execution_engine/requests/test_vars.toml -v
POST http://localhost:4000/api/v2/users
Header: Content-Type: application/json
URL: http://localhost:4000/api/v2/users
Body (json): {"email": "user-1ab47d11@swahira.io", "username": "user_1ab47d11", "role": "user"}
✓ SUCCESS: ./test_vars.toml (5ms)
╭──────────────────────────────────────────────────────────────────────────╮
│ RUMOUR EXECUTION REPORT │
├──────────────────────────────────────────────────────────────────────────┤
│ Total Requests: 1 │
│ Successful: 1 │
│ Failed: 0 │
│ Skipped: 0 │
│ Success Rate: 100.0% │
│ Total Time: 12ms │
╰──────────────────────────────────────────────────────────────────────────╯
✓ Successful Requests:
- ./test_vars.toml [201] [12ms]
Actionable Recommendations:
→ Run with --json to export this report for your CI/CD pipeline.
2. Dependency Resolution
Explicit Dependencies
First, initialize a workspace and scaffold a collection:
rumour init engine_examples
cd engine_examples
rumour new execution_engine -y
If get_user.toml requires a user to be created first, you declare the dependency explicitly. Rumour will automatically wait to run get_user.toml until create_user.toml has successfully completed.
execution_engine/requests/create_user.toml
name = "Create User (Dependency Root)"
[request]
method = "POST"
url = "http://localhost:4000/api/v2/users"
[headers]
"Content-Type" = "application/json"
[body]
type = "json"
raw = '{"email": "test@swahira.io", "username": "testuser", "role": "user"}'
[assert]
status = 201
[extract]
user_id = "id"
execution_engine/requests/get_user.toml
[dependencies]
"create_user.toml" = ["user_id"]
[request]
method = "GET"
url = "http://localhost:4000/api/v2/users/{{user_id}}"
Implicit Dependencies via Vault/Environment
If a variable isn't mapped in [dependencies], Rumour will attempt to resolve it from the environment or Vault. If the variable is missing completely, the request will immediately fail before network execution.
3. Parallel Execution (--parallel)
Because Rumour understands exactly which requests depend on which other requests, it can automatically determine which nodes are completely independent.
By running with the --parallel (or -p) flag, Rumour will group the execution graph into "levels" and execute all independent requests simultaneously, vastly accelerating test suites.
$ rumour run ./execution_engine/requests/ -p -v
POST http://localhost:4000/api/v2/users
Header: Content-Type: application/json
URL: http://localhost:4000/api/v2/users
Body (json): {"email": "test@swahira.io", "username": "testuser", "role": "user"}
✓ SUCCESS: ./create_user.toml (5ms)
GET http://localhost:4000/api/v2/users/28
URL: http://localhost:4000/api/v2/users/28
POST http://localhost:4000/api/v2/users
Header: Content-Type: application/json
URL: http://localhost:4000/api/v2/users
Body (json): {"email": "user-268a2963@swahira.io", "username": "user_268a2963", "role": "user"}
✓ SUCCESS: ./get_user.toml (3ms)
✓ SUCCESS: ./test_vars.toml (2ms)
╭──────────────────────────────────────────────────────────────────────────╮
│ RUMOUR EXECUTION REPORT │
├──────────────────────────────────────────────────────────────────────────┤
│ Total Requests: 3 │
│ Successful: 3 │
│ Failed: 0 │
│ Skipped: 0 │
│ Success Rate: 100.0% │
│ Total Time: 23ms │
╰──────────────────────────────────────────────────────────────────────────╯
✓ Successful Requests:
- ./create_user.toml [201] [10ms]
- ./get_user.toml [200] [7ms]
- ./test_vars.toml [201] [10ms]
Actionable Recommendations:
→ Run with --json to export this report for your CI/CD pipeline.
- Safety Guarantee: Rumour guarantees that a dependent request will never execute before its parent has finished and exported the necessary variables, even in parallel mode.
- Concurrency Control: The
--concurrencyflag sets the absolute maximum number of simultaneous network connections Rumour is allowed to open.
4. Execution Step Mode (--step)
When writing complex workflows, debugging variable extraction can be tricky. You can use the --step flag to force Rumour to pause execution after every single request and wait for your explicit confirmation before proceeding.
rumour run ./complex_flow/ --step
This acts as a debugger for your test suites, allowing you to inspect logs, database state, or external side-effects between each API call.