1

I'll like to know what are the things to consider when choosing between configuring an app as static or as dynamic in an Apache 2 server that uses mod_fastcgi. The app is a typical reporting app written in Perl with MySQL as the Db backend with fairly medium traffic. I'll love to hear your experiences about running FastCGI in such a scenario.

1 Answer 1

3

Neither of them really has set performance or scalability characteristics divorced from the context of your app and its environment. Which would work better depends on what you have going on.

Static: set number of app processes that hang around all the time. Conditions that argue for this include:

  1. You can afford to have enough instances of the app hanging around all the time to speedily serve as much traffic as you ever get, for whatever reason (the machine doesn't need to do anything much else, you never really get that much traffic, the machine has lots of spare resources, what-have-you).
  2. An app process instance has significant startup time and your users will be annoyed by it.
  3. The machine needs to only ever have some set proportion of its resources used up by this app so that other jobs can run without undue interference.

Dynamic: variable number of app processes that are started on demand and killed off when unused. Conditions that argue for this include:

  1. Your traffic is very spiky (self-similar), so that it's important to be able to spawn more app processes to handle it.
  2. An app process instance starts up very quickly, so it doesn't do much harm if one needs to be spawned to handle a request.
  3. The machine does need its resources for other purposes, so it's nice to free them up when you can, but it's okay to soak up a lot of them for this app when its traffic is heavy.
0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .