You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Simon Funnell <si...@propositum.biz> on 2010/10/19 06:20:23 UTC

APR Features

Hi,

I wanted to know if it was worth using the sendfile features for small 
static files or is the APR already optimised for serving static content?

I basically have a jsp that makes a choice between serving up a static 
(.html) and custom version of the page dependant on whether the user is 
authenticated.

If the user is not authenticated the required sendfile request 
attributes for the static version are set and the body of the jsp 
disregarded. The static versions are about 10-20k and it works fine.

I guess my question is, if I use <jsp:forward page="/index.html" /> 
instead of sendfile, is their any difference?

I figure that if I have lots of unauthenticated users this will help 
with maintaining the load.

Regards,

Simon


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


Re: APR Features

Posted by Mark Thomas <ma...@apache.org>.
On 18/10/2010 23:20, Simon Funnell wrote:
> Hi,
> 
> I wanted to know if it was worth using the sendfile features for small
> static files or is the APR already optimised for serving static content?
> 
> I basically have a jsp that makes a choice between serving up a static
> (.html) and custom version of the page dependant on whether the user is
> authenticated.
> 
> If the user is not authenticated the required sendfile request
> attributes for the static version are set and the body of the jsp
> disregarded. The static versions are about 10-20k and it works fine.
> 
> I guess my question is, if I use <jsp:forward page="/index.html" />
> instead of sendfile, is their any difference?

YMMV. The best way to answer that question for your environment is to
run some tests and see.

Mark



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