tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mehdi Sarmadi <msarm...@gmail.com>
Subject Re: Problem with making HTTP KeepAlive work
Date Thu, 12 Apr 2012 13:14:49 GMT
Assuming keep-alive being on by default in HTTP/1.1 how come, apache does
not work that way?
I mean even I force HTTP/1.1 in apache with Keep-Alive On, it sends back
"Connection: KeepAlive" in HTTP Response?
Moreover, turning keepalive feature on, makes Apache response about 8 to 10
times more than the time it is not On, but tomcat does not behave the same
and I can't see Improvements in number of concurrent sessions.
--
Mehdi Sarmadi


On Thu, Apr 12, 2012 at 5:36 PM, Mehdi Sarmadi <msarmadi@gmail.com> wrote:

> you'r right just fixed it.
>
> <Connector maxKeepAliveRequests="50000" port="7070" protocol="HTTP/1.1"
> allowTrace="false" connectionTimeout="20000" clientAuth="false" />
>
> anyway, I can't still find the "Connection: Keep-Alive" HTTP Response(from
> tomcat) header. I just don't know where to check, any clues? anything
> missing?
>
> --
> Mehdi Sarmadi
>
>
>
> On Thu, Apr 12, 2012 at 5:28 PM, Konstantin Kolinko <
> knst.kolinko@gmail.com> wrote:
>
>> 2012/4/12 Mehdi Sarmadi <msarmadi@gmail.com>:
>> >
>> >  I just setup a tomcat 7 on linux for test. I just used this connection
>> > property in server.xml
>> >
>> > here is out connector
>> > <Connector maxKeepAliveRequests=-1 port="7070" protocol="HTTP/1.1"
>> > allowTrace="false" connectionTimeout="20000" clientAuth="false" />
>> >
>> > , but when we try to connect from a client "Firefox" in my case,
>> > "Connection: Keep-Alive" is sent in the Request by Browser but
>> "Connection:
>> > Keep-Alive" is not visible in the HTTP Response Headers, which obviously
>> > coming from weblogic. I use HTTPFox plugin.
>> >
>> >  So I guess that  that config does not work. Something seems to be
>> missing.
>> >  Any suggestion for making HTTP KeepAlive work in Tomcat?
>> >
>>
>> Connection: Keep-Alive  header has different meaning.
>>
>> It is needed only when you have Keep-Alive: header as well so that
>> "Keep-Alive" header value is not lost at proxies.
>>
>> Keep alive feature of HTTP/1.1 does not need to be specified in the
>> response. It is "on" by default. See RFC2616 aka HTTP/1.1
>> specification.
>>
>>
>> By the way:
>> 1. You are missing quotes around "-1". The above is broken XML.
>> 2. You will get the same response even if you remove the
>> maxKeepAliveRequests attribute.
>>
>> Best regards,
>> Konstantin Kolinko
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message