3 Replies Latest reply on Sep 8, 2006 1:37 AM by adilev

    Calling to develop JBoss Batch container....

    adilev

      Following a talk with the cheif architecture of WebSphere, Bob High, they are now pushing a new container, which works with EJB in a batch mode.
      Mainly a batch is a non interactive operation, that take a long time on big set.

      You usually do a loop on a set, creating a checkpoint every x iteration, so in case of failure you can continue from this point.
      You usually do commit at such points and persistance the checkpoint iterator value.

      One usage of EJB CMP type is to prefatch the EJB based on the order keys. Also if supoort of clustering per key range, than it can be process in parrallel. Also you can control the priority of the task so it will be lower than OLTP (on line transaction) when OLTP responses become slower.

      Comapnies like Intentia, Cardnet and others which had to process more than 100K items have used J2SE programs to do so or extend the J2EE web side behind spec. Here the idea is to enter batch container to spec and IBM is conducting such an effort, and your help guys, will help both side, a mostly developers, to get a usefull container.

        • 1. Re: Calling to develop JBoss Batch container....
          starksm64

          And where is the spec behind this?

          • 2. Re: Calling to develop JBoss Batch container....
            adilev

            As IBM refuse to co-operate, I do sugegst to submit a JSR. I invite Jboss to join. I have already talked with Mark Flury regarding this.

            I have develop a prototype of container, and believe that the correct way is to link a calling class to a called class in EJB3 is an annotation like:

            @batch(checkpoint=200,priority=2,pause=30ms,callingBean=com.x.y)
            class x {
            }

            I am starting the procedure for JCP JSR and Inviting JBoss to particapte.

            With apprication

            Adi Lev

            • 3. Re: Calling to develop JBoss Batch container....
              adilev

              In J2EE 1.4 there is a resource.spi.work that seems a good API to activate work at schedule time. JBoss support J2EE 1.4.
              Next there is the layer of the batch processing itself.
              The layer is:
              External loop in step on batch size - I call this paginaging batch proccess. It do some kind of select to retrieve arguments from a database (e.g. Customaers ID)
              This loop is responsible to set in the database the execution point it succesful commit (in page size)
              Than there is the inner loop on the current page data
              Than there is an executing procedure (Method) that is called and process the task based on parameters that come from the current record selection
              Listener to the worker manager should be the executing inner procedure for tasks like release immidate as well the outer procedure for tasks like pause resume

              I have implemented a similar thing but not using J2EE 1.4 but simply thread notification simply because the WebSphere I used is 5.0 at that time. J2EE 1.4 added release, resource.spi.work

              In the Jboss above thread I suggested to create an annotaion to the inner procedure, which will create the code and calling to the above