tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Konstantin Kolinko <knst.koli...@gmail.com>
Subject Re: wget and Tomcat resources
Date Thu, 14 Jun 2012 07:50:50 GMT
2012/6/14 Miguel González Castaños <miguel_3_gonzalez@yahoo.es>:
> Dear all,
>
>  Our developer has set a cronjob similar to this:
>
>  wget -T 0 http://ourserver.com/email_sender
>
>  which calls a javabean to check pending emails to send in a database and
> actually send them.
>
>  I'm concerned about this, since I have realized that we have peaks of 500
> http connections per minute exactly about the same time this cronjob runs.
> I'm just wondering if this cronjob is performing several retries (since it
> sets a 0 timeout) and count as http hits.
>
>  This increase of http hits (not related to people connecting since people
> connect in office hours and this happens early morning) is happening
> together with an increase of use of memory.

1. Configure your AccessLogValve to print "User-Agent" header of the
request (%{User-Agent}i ). This way you will know what requests come
from wget and how fast they are served by Tomcat.

2. Make sure that the page contacted by wget does not use sessions. If
each request creates a new session it would be a waste of resources.
You can include session id into AccessLogValve configuration: %S

Best regards,
Konstantin Kolinko

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


Mime
View raw message