Re: starting threads from servlets



Fernando wrote:
    public synchronized void start() {
        while(true) {
            try {
             	verificar();//checks something
                sleep(60000);
            } catch (InterruptedException e) {
                //?
            }
        }
    }

You do not say, but it is clear that you are extending Thread and you misunderstood how that works.

<http://java.sun.com/j2se/1.4.2/docs/api/>

BTW. How is the thread going to stop?
.



Relevant Pages