lihao has asked for the wisdom of the Perl Monks concerning the following question:
Dear Monks:
Under FastCGI processes, is there a good way to update a preloaded Perl Module just like Apache::Reload for mod_perl users. I am currently using kill -9 to restart the fcgi process, so each time I get some changes on my modules, I have to restart(kill) fcgi process to update these changes.. Is there any better way to do this?? I am using Apache2.0.59, mod_fastcgi/2.4.2, CGI::Fast with HTML::Mason.
A couple of days ago, I asked this question in FCGI's mailing group, some suggestions include:
For suggestion-(1), I think I can do things like
if ( -M "/path/to/lib/MyModule.pm" < 0 ) { require MyModule; MyModule->import(qw[ :mytag ]); }
But my questions keep:
For the suggestion-(2), I am not sure which SIG should I trap to handle the file change
Thanks for your further advices..
Best regrads,
Lihao(XC)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: FastCGI and mod_perl's Apache::Reload equivalent???
by shmem (Chancellor) on Dec 13, 2007 at 22:06 UTC | |
|
Re: FastCGI and mod_perl's Apache::Reload equivalent???
by CountZero (Bishop) on Dec 13, 2007 at 21:13 UTC | |
|
Re: FastCGI and mod_perl's Apache::Reload equivalent???
by Errto (Vicar) on Dec 13, 2007 at 21:56 UTC | |
|
Re: FastCGI and mod_perl's Apache::Reload equivalent???
by suaveant (Parson) on Dec 13, 2007 at 20:46 UTC | |
|
Re: FastCGI and mod_perl's Apache::Reload equivalent???
by lihao (Monk) on Dec 14, 2007 at 05:31 UTC | |
by lihao (Monk) on Dec 16, 2007 at 05:37 UTC |