3 ms·
It depends. If you're caching ("weakly" eg with revalidating If-Modified-Since against mtime, or even "strongly" eg aggressively), which you should, you're crea
by tannhaeuser 6y ago
It depends. If you're caching ("weakly" eg with revalidating If-Modified-Since against mtime, or even "strongly" eg aggressively), which you should, you're creating processes only for a small fraction of requests. Remaining major overhead is reparsing dynamic language backend code, which you can further reduce by using native code.
- spenczar5 6y agoThe cache is served by an HTTP server still, though. What you are describing is a sort of hybrid, where most requests are handled in threads (either OS or green threads) but a small fraction get their own process. I think I agree that that could work, but it sounds a bit different from creating a process per connection. I don’t think parsing code is the major overhead. Its not really about starting the processes so much as switching between them when concurrently handling a bunch of requests.