3 Replies Latest reply on May 15, 2009 1:28 PM by dirk65mb

    How to implement a batch process?

      Hi,
      I got information from inside JBoss that I could use ESB also to maintain a huge amount of batch processes. The processes I talking about are triggered once and should run forever. Althought I got this information I couldn't found an example how I can implement this inside the esb.
      Any advice is welcome,

      Regards Dirk

        • 1. Re: How to implement a batch process?
          tfennelly

          This could be done using a Scheduled Listener implementation. There's info about this in the docs (programmers guide).

          • 2. Re: How to implement a batch process?
            ryanhos

            JBossESB is great (mostly), but you might be better off with a batch processing system like CA Autosys or even just simply cron (or perhaps even quartz inside JBoss or JBoss Scheduler )

            http://www.len.ro/2008/10/another-way-to-use-quartz-in-jboss
            http://www.jboss.org/community/wiki/Scheduler

            Reasons you probably shouldn't use JBoss ESB:
            1.) What use does a self-contained, long-running batch process have for messaging?
            2.) Your batch processes will be constrained to the threading model of the app server, as you shouldn't be starting your own threads inside JBoss.**
            3.) You'll need to have hot-deploy on in production and stop an entire ESB component in order to redeploy schedule changes. I suspect that this will stop the currently running batch process. Thus, you'll be stuck with one deployment unit (.esb archive) per batch process if you need flexibility.

            **The Quartz and JBoss Scheduler solutions are are susceptible to weakness #2 also.

            Don't get me wrong, I'd love to have another user so this project becomes more popular and gets more attention and perhaps more paid developers (or more volunteer developers, even), but I'm not sure JBoss ESB is the way to go for you.

            • 3. Re: How to implement a batch process?

              Thanks for the replies so far.
              At the moment we've an framework for batch processes developed by ourselfs. This framework is running on production but is difficult to maintain and to extend. So the idea came for a platform where we can deploy modules "the batch processes" and each module can be indivudaly stopped and started. On the esb you could use JBoss ON and the adminstrators have a frondend to maintain the processes.
              ryanhos:
              1. We can rewrite some processes to put messages on a queue or topic. But still this proces use a callback structure to retrieve data information which we need for backend processes.
              2. I agree with this, but in the older documentation from ESB Rosetta they had also to deal with this problem. I was hoping that this part BatchProcess is also in the jboss esb.
              3. Is the feature we want.

              Any advice or ideas.

              Dirk