| Copyright | (c) Tim Watson 2017 |
|---|---|
| License | BSD3 (see the file LICENSE) |
| Maintainer | Tim Watson <watson.timothy@gmail.com> |
| Stability | experimental |
| Portability | non-portable (requires concurrency) |
| Safe Haskell | None |
| Language | Haskell98 |
Control.Distributed.Process.Supervisor.Management
Contents
Description
- supervisionAgentId :: MxAgentId
- supervisionMonitor :: Process ProcessId
- monitorSupervisor :: SupervisorPid -> Process (ReceivePort MxSupervisor)
- unmonitorSupervisor :: SupervisorPid -> Process ()
- data MxSupervisor
- = SupervisorBranchRestarted { }
- | SupervisedChildRestarting { }
- | SupervisedChildStarted { }
- | SupervisedChildStartFailure { }
- | SupervisedChildDied { }
- | SupervisedChildInitFailed { }
- | SupervisedChildStopped { }
- | SupervisorShutdown { }
Documentation
supervisionAgentId :: MxAgentId Source #
The MxAgentId for the node monitoring agent.
supervisionMonitor :: Process ProcessId Source #
Starts the supervision monitoring agent.
monitorSupervisor :: SupervisorPid -> Process (ReceivePort MxSupervisor) Source #
Monitor the supervisor for the given pid. Binds a typed channel to the
calling process, to which the resulting ReceivePort belongs.
Multiple monitors can be created for any calling process - sup pair.
Each monitor maintains its own typed channel, which will only contain
MxSupervisor entries obtained after the channel was established.
unmonitorSupervisor :: SupervisorPid -> Process () Source #
Removes all monitors for sup, associated with the calling process.
It is not possible to delete individual monitors (i.e. typed channels).
Mx Event Type
data MxSupervisor Source #
Supervisor event data published to the management API
Constructors
| SupervisorBranchRestarted | A branch restart took place |
Fields | |
| SupervisedChildRestarting | A child is being restarted |
Fields | |
| SupervisedChildStarted | A child has been started |
Fields | |
| SupervisedChildStartFailure | A child failed to start |
Fields | |
| SupervisedChildDied | A child process death was detected |
Fields | |
| SupervisedChildInitFailed | A child failed during init |
Fields | |
| SupervisedChildStopped | A child has been stopped |
Fields | |
| SupervisorShutdown | A supervisor is shutting down |
Fields | |
Instances