Net::Server::Fork - Net::Server personality |
Net::Server::Fork - Net::Server personality
use Net::Server::Fork; @ISA = qw(Net::Server::Fork);
sub process_request { #...code... }
__PACKAGE__->run();
Please read the pod on Net::Server first. This module is a personality, or extension, or sub class, of the Net::Server module.
This personality binds to one or more ports and then waits for a client connection. When a connection is received, the server forks a child. The child handles the request and then closes.
With the exception of parent/child signaling, this module will work (with basic functionality) on Win32 systems.
Process flow follows Net::Server until the post_accept phase. At this point a child is forked. The parent is immediately able to wait for another request. The child handles the request and then exits.
The Fork server has the following hooks in addition to the hooks provided by the Net::Server base class. See the Net::Server manpage
$self->pre_accept_hook()
$self->pre_fork_hook()
$self->post_accept_hook()
$self->run_dequeue()
Paul Seamons <paul@seamons.com>
Rob Brown <bbb@cpan.org>
Please see also the Net::Server::INET manpage, the Net::Server::PreFork manpage, the Net::Server::MultiType manpage, the Net::Server::SIG manpage the Net::Server::Single manpage
Net::Server::Fork - Net::Server personality |