NAME
Supervisor::Controller - Controls the Superviors environment
SYNOPSIS
my $supervisor = Supervisor::Controller->new(
Name => 'supervisor',
Logfile => '/dev/stdout',
Processes => Supervisor::ProcessFactory->load(
Config => 'supervisor.ini',
Supervisor => 'supervisor'
)
);
$supervisor->run;
or with the RPC interaction
my $supervisor = Supervisor::Controller->new(
Name => 'supervisor',
Logfile => '/dev/stdout',
Processes => Supervisor::ProcessFactory->load(
Config => 'supervisor.ini',
Supervisor => 'suprvisor',
),
RPC => Supervisor::RPC::Server->new(
Name => 'rpc',
Port => 9505,
Address => 127.0.0.1,
Logfile => '/dev/stdout'
Supervisor => 'supervisor',
)
);
$supervisor->run;
DESCRIPTION
This module is designed to control multiple managed processes. It will attempt to keep them running. Additionally it will shut them down when the supervisor is signalled to stop. The following signals will start the shutdown actions:
INT
TERM
HUP
QUIT
ABRT
Optionally it can allow external agents access, so that they can interact with the managed processes thru a RPC mechaniasm.
PARAMETERS
- Name
-
The name for the supervisors session.
- Logfile
-
The name of the logfile for the supervisor
- Processes
-
The managed processes that the supervisor will manage.
- RPC
-
The rpc server to interact with and on behalf of the processes.
METHODS
- run
-
This method starts the endless loop.
SEE ALSO
Supervisor
Supervisor::Base
Supervisor::Class
Supervisor::Constants
Supervisor::Controller
Supervisor::Log
Supervisor::Process
Supervisor::ProcessFactory
Supervisor::Session
Supervisor::Utils
Supervisor::RPC::Server
Supervisor::RPC::Client
AUTHOR
Kevin L. Esteb, <kesteb@wsipc.org>
COPYRIGHT AND LICENSE
Copyright (C) 2009 by Kevin L. Esteb
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.5 or, at your option, any later version of Perl 5 you may have available.