In a servlet that <loads on start up>
The init method trys to create a new Automate();
But it does not. The init method terminates at that point and when the
servlet is eventually called by URL
the init method runs again and again terminates at the same point.
The only time any exceptions are thrown is the second time round (because
stuff at the end of the init that is never executed is vital).
Heres the class it doesn't like. None of the Sys.out's are executed.
public class Automate {
static Timer timer;
static Weather forecast;
static int count;
static String[] month = {"","","","","","","","","","","",""};
Automate() {
System.out.println("1");
timer = new Timer();
System.out.println("2");
count=0;
System.out.println("3");
if(!UKRoutes.weatherOn) {forecast = new Weather(true);}
System.out.println("4");
timer.schedule(new AutoMaintain(), 0);
System.out.println("5");
timer.schedule(new AutoWeather(), 0);
System.out.println("6");
}
--
TIA
Mike W.
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html