Spare-thread-min

From Resin 3.0

Revision as of 17:36, 6 January 2006 by Ferg (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search


spare-thread-min configures the minimum number of spare threads Resin will try to keep in the thread pool.

Because thread creation is relatively expensive, the thread pool needs to keep a number of threads available to deal with spikes in load. With this pool of pre-allocated threads, Resin can serve requests for the spike without waiting for a new thread to be allocated.

priority threads

Resin uses the thread pool for requests and also for high-priority tasks like session and database timeouts. Because the timer tasks are higher priority, Resin reserves a number of threads for those tasks.

This means that setting thread-max to 100 and hitting the server with 200 clients may only serve 75 requests at a time, because 25 threads are reserved for the high-priority tasks.

Personal tools