tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ronald Klop <ronald-mailingl...@base.nl>
Subject Re: Trouble with java.util.Timer in Tomcat 5.5
Date Mon, 02 Jul 2007 08:24:43 GMT
Could it be the Timer is waiting for a previous action to finish? Maybe the FTP connect 'hangs'.

Ronald.



On Fri Jun 29 16:41:13 CEST 2007 Tomcat Users List <users@tomcat.apache.org> wrote:
> I have an app running in Tomcat 5.5.12, with jre 1.5.0_12 (explicitly 
> specified in the service configuration), on windows 2000 server.
> 
> I have one class that is initialized by a servletContextListener, in the 
> contextInitialized event. This class uses java.util.Timer and 
> java.util.TimerTask to check every few minutes for new files on an ftp 
> site, and if it finds any, it downloads and processes them. This all 
> works fine for anywhere from 2 or 3 days to a week or so, then the timer 
> just stops firing, and indicated by a sudden lack of entries in the log 
> file (I log every time the timer fires to help track down this problem).
> 
> Over the last couple of weeks, I've found some things that can cause 
> this, but I believe I've fixed them, but my timer still stops firing 
> after a few days. The things I've already fixed were updating the jre 
> to 1.5.12, because of problems with automatic time correction on the 
> server, and I found that unhandled exceptions in the timer task can also 
> cause this, so early last week I modified my code to trap all exceptions 
> before they can trickle up to the timer, and log them, and I don't see 
> any exceptions being logged.
> 
> It doesn't seem to be related to the number of executions, because the 
> latest time it stopped on me, it had fired around 1200 times, and the 
> time before that was around 4500 times. It can also be any time of day, 
> and sometimes the server is busy and other times it hasn't had a 
> connection for several hours.
> 
> Any other suggestions as to what I should look for to find this? 
> 
> Thanks!
> D
> 
> 
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> 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