André -- thank you for making this clear.

On 7/31/2014 2:27 PM, André Warnier wrote:
Caldarale, Charles R wrote:
From: Igal Sapir Subject: RE: Programmatically retrieve number of tomcat connections

Isn't Filter.doFilter() called once for each incoming http request?

Yes, which is why it has nothing to do with the number of _connections_.


To elaborate just a little :
Presumably when the OP wrote "connections", he meant "connections", and this was not just sloppy language.

In that case, consider "keep-alive" connections : a browser establishes *one* connection to Tomcat, and then uses that same connection to send 100 HTTP requests (and get 100 HTTP responses) over that same connection. A filter would count 100 requests (assuming that they are all to that same application), but there would still be a single connection. (On the other hand of course, if all the request were directed to another application which does not have the filter, then the filter would count 0 requests, and there would still be 1 connection).

Talking about fuzzy language though, review Mark's original response : which "connections" are we talking about here ? and are we talking about a "snapshot", where we want to know how many connections with Tomcat are active at a specific moment in time, or how many connections with Tomcat have been established/closed over a period of time ?
Or about something else altogether ?

And if one really wanted to count connections at the Tomcat level, I would imagine that the sensible place to do this would be at the Connector level, no ? (all of them)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org


--
Igal Sapir
Railo Core Developer
http://getRailo.org/


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to