5 Replies Latest reply: Jun 22, 2012 1:52 AM by Eric Elzinga RSS

    Calling two Business service using split join in osb

    Apsalom G
      Hi,

      While trying to call two business service using Split Join in osb i am getting selection failure message in Bpel em console. i am using invoke activity to invoke the BS and assign to assign the input. in the assign i am assigning *$request.payload/input* to input.payload . In the em console i am getting input like this


      receiveInput
      Jun 19, 2012 5:05:45 PM Received "process" call from partner "bpelprocess1_client"
      <payload>
      <inputVariable>
      <part name="payload">
      <client:process>xxxxx</client:process>
      </part>
      </inputVariable>
      Assign (pending)
      Jun 19, 2012 5:05:48 PM Error in evaluate <from> expression at line "65". The result is empty for the XPath expression : "/client:process/client:input".
      <payload>
      <client:process>xxxxxx</client:process>
      Jun 19, 2012 5:05:48 PM The following exception occurred while attempting to execute operation copy at line 63
      <payload>
      <bpelFault>
      <faultType>0</faultType>
      <selectionFailure/>
      </bpelFault>
      Jun 19, 2012 5:05:57 PM "BPELFault" has not been caught by a catch block.
      Jun 19, 2012 5:06:00 PM The transaction was rolled back. The work performed for bpel instance "650002" was rolled back, but the audit trail has been saved for this instance.If this is a sync request, please resubmit the request from the client. If it is an async request, please recover from the recovery console by resubmitting the invoke message.


      Can anyone help on this?

      Thanks in Advance...
        • 1. Re: Calling two Business service using split join in osb
          791885
          Hi,

          The Xpath seems correct. Can you double check if the namespace is correct?

          I assume that you are using an assign. This is sometimes difficult to debug. I suggest adding a transformation and see if this works. Make sure you test this first local at design time.

          Hopefully this should give you more clues why the assign is not working.

          Thanks

          Sander
          • 2. Re: Calling two Business service using split join in osb
            NarsingPumandla
            Hi,

            I have created a sample split join for you with a similar use case what you were trying, before the invoke activity with which you invoke a Business Service, drop an Assign activity Assign Action and write the body payload in the expression field and in the variable field i have selected my Invoke activity Input variable which is InvokeInput.payload.

            The Body payload i have pasted in the expression field looks like...

            ------------
            <ns2:process xmlns:ns2="http://xmlns.oracle.com/SOA11gApp/NamesMockService/BPELProcess1">
            <ns2:input>Sample Input</ns2:input>
            </ns2:process>
            -----------

            Hope this helps,
            N
            • 3. Re: Calling two Business service using split join in osb
              Apsalom G
              Thanks NarSing, that worked...
              • 4. Re: Calling two Business service using split join in osb
                Apsalom G
                hi,

                i am getting only one BS output in the response how to get two BS output in response. my response is looking like this

                <soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">
                <soap-env:Body>
                <ns2:NewOperationResponse xmlns:ns2="http://www.example.org/SjWsdl/">xxxxxxxx</ns2:NewOperationResponse>
                </soap-env:Body>
                </soap-env:Envelope>

                can u help on this?

                thanks in advance...
                • 5. Re: Calling two Business service using split join in osb
                  Eric Elzinga
                  maybe this one helps a bit, it's the same pattern

                  http://www.xenta.nl/blog/2011/07/03/oracle-service-bus-implementing-aggregator-pattern-by-use-of-split-join/

                  if you're using a dynamic split join easiest way is to do something like

                  assing <yourresponse/> to $response
                  at this moment your assign an empty placeholder to the response variable

                  now you go into the for-each looping and for each iteration you need to insert the response of your bpel call in the $response variable

                  so in the looping as last step you add something like

                  insert $mybpelresponse/rootelement into $response/yourresponse

                  with the insert it will insert the reponse 1..x times into the $response variable (so actually aggregating all the responses for you)