I'm trying to work out a good clean way of creating a Timer thread inside a
Resin 2.1.17 web container.
Does anyone know a good way of implementing this?

I have a requirement to perform some work-intensive background processing
inside my web app, but it's too intensive to be done during a normal
request/response cycle in my web application, so I'm looking for a way to
'spawn off' the processing - either into a Timer thread running in the
background, or in a separate background thread that will not delay the
response from the HTTP request coming in.

I could just spawn off a thread inside my request handler, but I fear this
is bad practice inside a web container, where the threads are managed by the
container itself.

Resin 3.0 has some lovely features like JCA and the Work Management API for
managing long-working threads which would solve my problem but unfortunately
I just can't upgrade at this point.

Any help would be greatly appreciated. Thanks.


PS. I'm using Resin 2.1.17 with Java 1.4.2_10 on Win XP (and also on Red Hat
My web app is mostly Struts/JSP with Oracle JDBC Thin drivers.

View this message in context: 
Sent from the Resin mailing list archive at Nabble.com.

resin-interest mailing list

Reply via email to