Re: File locking
"Matt" <fastcgi-developers-ZZ3zTlmqjYs1+lMOHNVa3ltFE3g8mehB@public.gmane.org>
| Newsgroups | gmane.comp.web.fastcgi.devel |
|---|---|
| Message-ID | <002f01c9fc6d$d090b8b0$e701a8c0@cu> |
In regards to running single or multiple instances of your program: http://www.fastcgi.com/mod_fastcgi/docs/mod_fastcgi.html Any URI that Apache identifies as a FastCGI application and which hasn't been explicitly configured using a FastCgiServer or FastCgiExternalServer directive is handled as a dynamic application (see the FastCgiConfig directive for more information). Dynamic applications are not started at server initialization, but upon demand. If the demand is heavy, additional application instances are started. As the demand fades, application instances are killed off. Many of the options govern this process. http://www.fastcgi.com/mod_fastcgi/docs/mod_fastcgi.html#FastCgiServer -init-start-delay n (1 second) The minimum number of seconds between the spawning of instances of this application. This delay decreases the demand placed on the system at server initialization. -processes n (1) The number of instances of the application to spawn at server initialization. http://www.fastcgi.com/mod_fastcgi/docs/mod_fastcgi.html#FastCgiConfig ^^ Theres many options which control instance spawning. As for file locking, someone else will need to answer that question. ----- Original Message ----- From: Heinrich Lee Yu To: fastcgi-developers-xGejAJT2w6xVgU18Zptdi0EOCMrvLtNR@public.gmane.org Sent: Saturday, July 04, 2009 3:03 PM Subject: [FASTCGI] File locking Hi, I'm planning to write a fastcgi application with an embedded mysql server using libmysqld. From my understanding, fastcgi spawns multiple instances of my application. This would result in multiple libmysqld servers running on the same data directory. (I also need them to run on the same data dir because data needs to be the same for all instances) Would i be having problems regarding file locking and such with this setup? Or does fastcgi handle this? Also, I know I could also just let fastcgi spawn only one instance of my application. In this case, would performance be significantly slower than with multiple processes? ------------------------------------------------------------------------------ _______________________________________________ FastCGI-developers mailing list FastCGI-developers-xGejAJT2w6xVgU18Zptdi0EOCMrvLtNR@public.gmane.org http://mailman.pins.net/mailman/listinfo.cgi/fastcgi-developers _______________________________________________ FastCGI-developers mailing list FastCGI-developers-xGejAJT2w6xVgU18Zptdi0EOCMrvLtNR@public.gmane.org http://mailman.pins.net/mailman/listinfo.cgi/fastcgi-developers