You might want to look at Spring Batch at
http://static.springsource.org/spring-batch/
Spring Batch can share your Spring Framework POJOs of your web
application but it really makes sense for these to be stand alone
processes as there is no user interaction.
--- Alan
Magnús Skúlason wrote:
Hi,
I need to execute some time intensive batch jobs in my application,
such as periodically loading data from a file into a database,
happening at regular intervals and taking maybe 10-20 minutes. I am
thinking about where I should put the logic, inside a Spring Manager
bean that I access with a web service, or if I should just write a
simple command line program to do this.
I of course would prefer to have it within my appfuse project since
then I can use my existing model/dao classes and have all my code base
in one place. But I am a little afraid that there might be some
pitfalls in running such a heavy batch job within the web container
and accessed through a web service, for example timeout and
performance problems. I would love to get some feedback on that. Also
am I maybe missing a better way, is there for instance some way of
calling a method of a Spring Manager bean in appfuse directly from the
command line? It would of course need to be setup in the same way (all
decencies injected).
best regards,
Magnus
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@appfuse.dev.java.net
For additional commands, e-mail: users-h...@appfuse.dev.java.net