Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Jetty 9 Proxy


On Thu, Oct 9, 2014 at 5:09 PM, Nils Kilden-Pedersen <nilskp@xxxxxxxxx> wrote:
> My question was specific to using the Jetty instance exclusively as a proxy,
> using AsyncProxyServlet.
> The assumption is that it's fully async, meaning that at no point in
> proxying a request does a thread/core wait/idle. If that assumption is true,
> what do I gain from adding more threads, other than increased context
> switching?

If you can guarantee that the whole processing is fully async, and
provided you give Jetty thread pool all the threads Jetty needs to
function (schedulers, background threads, selectors, acceptors, etc.),
then perhaps you can run with a "small" thread pool. I don't know
exactly what value that is, though.

Also, some operation gets dispatched in Jetty in any case; a typical
example are failures, since trying to close a connection may block.

We always recommend to give the Jetty thread pools plenty of room. If
it's not needed, Jetty won't even instantiate threads that won't use.
But if they are needed, Jetty has room to do things, rather than
halting for lack of threads.

Simone Bordet
Developer advice, training, services and support
from the Jetty & CometD experts.
Intalio, the modern way to build business applications.

Back to the top