Raxol.Core.ErrorRecovery.RecoveryWrapper (Raxol v2.0.1)
View SourceWrapper module that adds recovery capabilities to any GenServer process.
This module wraps existing GenServers to provide enhanced error recovery features without requiring modifications to the original modules.
Features
- Automatic context preservation before termination
- State restoration after restart
- Error pattern recording
- Performance impact monitoring
- Graceful shutdown handling
Usage
# Start a wrapped process
RecoveryWrapper.start_link(MyWorker, [
worker_args: [arg1, arg2],
context_key: :my_worker,
recovery_supervisor: RecoverySupervisor
])
Summary
Functions
Returns a specification to start this module under a supervisor.
Get recovery statistics for the wrapped process.
Get the current state of the wrapped process.
Manually trigger a state snapshot.
Types
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
Get recovery statistics for the wrapped process.
Get the current state of the wrapped process.
Manually trigger a state snapshot.