tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pid <>
Subject Re: fail to download large static files in tomcat
Date Thu, 28 Jul 2011 08:16:17 GMT
On 28/07/2011 07:31, Michal Singer wrote:
> Regarding the question I asked on downloading large static files a while ago, I got a
reply now:
> hi,
> i got the same issue today, environment: windows xp, tomcat 7 with nio connector;
> it works after i try to add useSendfile="false" in server.xml Connector section;
> you could have a try

What works?

> I answered this person:
> Thanks, it looks like it works :)
> Do you also use compression=true?
> I am not sure what is faster, nio or http? 

This doesn't make sense.  The NIO & BIO connectors both service HTTP.

> The first time nio is used, it is very slow, but then it is faster than regular http.


> But if the client calls the nio once, it will be very slow.


> I also saw that useSendfiles is better in performance since it will reduce cpu cycles:
> sendFile" mode, Tomcat tells the O/S to transfer the contents of the file  directly to
the socket (bypassing reading it in to Tomcat memory).
> So, isn't it a decrease in performance to set it to false?
> Thanks for the answer.

sendfile can lead to performance increases, it depends on the application.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message