Doesn't AJP "multiplex" traffic, that is queued up requests are "serialized" through one connection that remains connected and it switches between servlets on the receiving end? and recycles the execution thread?

At 19:19 3/7/2007, you wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Rémy,

Rémy Maucherat wrote:
> The scalability improvement is twofold for AJP:
> - when running many Apache frontend servers (each with a sizeable
> number of workers), Tomcat would need a huge amount of AJP worker
> threads with the java.io connector

Makes sense. So, instead of a Java thread waiting in every single ajp
connection, you're using one native listener thread waiting on a
select(), right? It's sad that you can't do this in Java :(

> - threads will only be used for actually executing requests, thus
> making concurrency in business logic a bit more predictable (if you
> have 2000 threads, it's ok most of the time, as long as no lock gets
> contested by too many threads, in which case it's far better if you
> had only 200 threads)

Definitely. Unless I'm mistaken, Java threads on Linux are pthreads,
which are relatively heavy. Reducing them is certainly going to reduce
memory, thread counts (wrt system limits), and thread dump lengths.

> It also saves memory (no surprise). Socket polling will only be used
> for keepalive: during the processing of a request, the connector uses
> regular blocking IO.

Cool. So, it /does/ sound like something worth looking into. APR
installation looks like a snap, too, so it shouldn't be painful at all.

Thanks for the explanation, Rémy.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFF71aP9CaO5/Lv0PARAk7yAKCmhD9Xg5yH1yb5FNSrkeuP8uc0fQCeI9i8
E2Yjiq1jJR9SNcAOMErVJjQ=
=FEvG
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to