|
![]() |
![]() |
![]() |
3.6.6. concurrency The concurrency option specifies the concurrency mode that the engine will operate in. The Spyce engine can process requests serially (i.e. non-concurrently or one-at-a-time), or in parallel using either process-level (forking) or thread-level (threading) concurrency. Note that this option affects the request processing parallelism of a single engine. Request processing parallelism may also be acheived by running multiple instances of the engine, and this choice is independent of the follow discussion. The "one shot" Spyce configurations, namely CGI-based or command-line execution, are unaffected by the concurrency option, since the server only processes one request per Spyce engine invocation. The FastCGI configuration does not currently support parallel request processing due to a limitation of the FastCGI interface code (not anything inherent to the core of the Spyce engine). This will be remedied in the future. The mod_python configuration does not support parallel request processing within a single engine, since it is not supported by the mod_python interface. In fact, many mod_python compilations do not even allow threading in the Python interpretter. However, mod_python configurations run one Spyce engine per Apache child, and achieve request processing parallelism in this way. Lastly, the Spyce engine can be run in webserver mode. This mode is affected by the concurrency mode. The webserver runs in serial mode by default. It can fork a new process for each request. Alternatively, it can spawn a new thread for each request, if threading is supported by the Python interpretter. The possible values for the concurrency option are 'thread' (or 'threading') and 'fork' (or 'forking'). Any other value results in a serial execution, which is also the default.
| |||||||||||||||
|