logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

FCGI::Engine::ProcManager - module for managing FastCGI applications.

Author

       Stevan Little <stevan@iinteractive.com>

Bugs

       All complex software has bugs lurking in it, and this module is no exception. If you find  a  bug  please
       either email me, or add the bug to cpan-RT.

Description

       This module is a refactoring of FCGI::ProcManager, it behaves exactly the same, but the API is a little
       different. The function-oriented API has been removed in favor of object-oriented API. The "pm_" prefix
       has been removed from  the hook routines and instead they now use the "augment" and "inner" functionality
       from Moose. More docs will come eventually.

   SignalHandling
       FCGI::Engine::ProcManager attempts to do the right thing for proper shutdowns.

       When it receives a SIGHUP, it sends a SIGTERM to each of its children, and then resumes its normal
       operations.

       When it receives a SIGTERM, it sends a SIGTERM to each of its children, sets an alarm(3) "die timeout"
       handler, and waits for each of its children to die.  If all children die before this timeout, process
       manager exits with return status 0.  If all children do not die by the time the "die timeout" occurs, the
       process manager sends a SIGKILL to each of the remaining children, and exists with return status 1.

       FCGI::Engine::ProcManager uses POSIX::sigaction() to override the default SA_RESTART policy used for
       perl's %SIG behavior.  Specifically, the process manager never uses SA_RESTART, while the child FastCGI
       servers turn off SA_RESTART around the accept loop, but re-enstate it otherwise.

       The desired (and implemented) effect is to give a request as big a chance as possible to succeed and to
       delay their exits until after their request, while allowing the FastCGI servers waiting for new requests
       to die right away.

Methods

       I will fill this in more eventually, but for now if you really wanna know, read the source.

Name

       FCGI::Engine::ProcManager - module for managing FastCGI applications.

See Also

       FCGI::ProcManager
           This  module  is  a  fork of the FCGI::ProcManager code, with lots of code cleanup as well as general
           Moosificaition.

See Also