Hot Reload
Update agent WASM binaries without stopping the runtime.
Reload command
akshi reload
This reloads all agents whose WASM files have changed on disk. Agents whose binaries are unchanged continue running without interruption.
Reload a specific agent
akshi reload --agent log-monitor
What happens during reload
- The runtime detects the updated WASM binary.
- The current agent tick (if running) completes.
- The old WASM module is unloaded.
- The new WASM module is compiled and instantiated.
- The agent resumes with its existing journal and database state.
There is a brief pause between steps 3 and 4. No ticks are skipped; the next tick uses the new code.
Zero-downtime updates
For production deployments:
- Build the new WASM binary.
- Copy it to the configured
wasm_path. - Run
akshi reload. - Verify with
akshi status.
cargo build --target wasm32-wasip1 --release
cp target/wasm32-wasip1/release/my_agent.wasm agents/
akshi reload --agent my-agent
akshi status
Configuration changes
akshi reload only reloads WASM binaries. To apply configuration changes
(tick interval, capabilities, routes), restart the runtime:
akshi stop && akshi run
File watching (development)
In development, enable automatic reload on file changes:
akshi run --watch
This watches all configured wasm_path files and reloads automatically when
they change.