INF: SQL NT Thread PoolingLast reviewed: April 3, 1997Article ID: Q110673 |
The information in this article applies to:
- Microsoft SQL Server, version 4.2
SUMMARYMicrosoft SQL Server uses a concept called thread pooling to optimize performance when very large numbers of clients are connected.
MORE INFORMATIONNormally, a separate operating system thread is spawned for each client connection. This thread-per-connection architecture consumes less system overhead than the process-per-connection approach of some other products. However, at very high connection numbers (usually hundreds), even using a thread-per-connection can consume operating system overhead. Therefore, SQL Server can use a technique called thread pooling, whereby a pool of worker threads services a larger number of client connections. By default, this worker thread limit is 255, and can be viewed or changed with sp_configure, as "max worker threads." When this limit is reached, the SQL Server kernel message:
The working thread limit of 255 has been reachedis printed in the errorlog. Below this point, a new thread is spawned for each user connection. Above this thread limit, new connections will share the existing pool of worker threads. Since there are then more connections than threads, each new request is handled by the next worker thread that completes its current task. This process is quite efficient, as it is uncommon to have more than 255 (or whatever the max worker thread setting is) pending requests, even on a system with hundreds of clients.
|
Additional query words: 4.20 Windows NT
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |