3 Replies Latest reply on Mar 8, 2010 10:39 AM by Hans Wolffenbuttel

    Return From ESB pipeline

    Poyan Gerami Novice

      Hello,

       

      Is thair any way to return fron an ESB pipeline ? I have an synchron part and asyncron part. When i have call one backend i whant to return the response to the client and go on and do other things in the same service.

       

      I can use org.jboss.soa.esb.actions.StaticWiretap for routing the message to another service and go on in the same service and return to client. But I whant to avoid to create anather service.

       

      MY PipeLine service:

       

       

      * Webservice Front

      * call backend synchron

      * return hear to the client.      ---> Hear i whant to return to the client.

      * some action

      * call other backend asynch

       

       

      Thanks.

        • 1. Re: Return From ESB pipeline
          Nikos Massios Novice

          I would do it like that

           

          Service 1

          * Webservice Front

          * call backend synchron

          * invoke "Service 2" asynchronously

          * return hear to the client.      ---> Hear i whant to return to the client.

           

          Service 2

           

          * some action

          * call other backend asynch

          • 2. Re: Return From ESB pipeline
            Poyan Gerami Novice
            yes, i can do that, but is it possible to avoid 2 services ?
            • 3. Re: Return From ESB pipeline
              Hans Wolffenbuttel Expert

              Hi Poyan,

               

               

              if you want to use but one service you need to put everything in one pipeline:

               

               

              * Webservice Front

              * call backend synchron

              * some action

              * call other backend asynch

              * return here to the client.      ---> Here i whant to return to the client.

               

              Otherwise you need 2 services. You can't return a response in the middle of a pipeline as far as I know. You can however send a message to the reply-queue but I don't know what will happen if you do that within the same request-response pipeline.

               

              For efficiency I would suggest to implement the 2 sevices configuration.

               

               

              Regards,

               

              Hans