Folks,

I've run into problems with the SCA BPEL implementation and the way it interacts with the ODE engine - and I need help from some ODE experts, please.

OK, the SCA code is using the ODE engine in an embedded mode - and the Tuscany code is trying to supply all the information and interfaces for each BPEL process to the ODE Engine - and in particular it aims to bypass the ODE database store so far as the BPEL process and its configuration are concerned.

So - Tuscany now has its own version of the ProcessConfImpl (I sent a version of this out in a previous email). One thing I discovered is that it is necessary for the Tuscany ProcessConfImpl to return "true" to the isTransient() method. Otherwise, the ODE engine seems to try to find information about the process in the database with nasty consequences (failed transactions).

HOWEVER, this has a side effect that is both curious and problematic.

Using the ODE ProcessConfImpl (and by implication the database store for the process itself), for a trivial "Hello World" BPEL process, when the "hello" operation is invoked on the BPEL process, the ODE engine returns the result message as a "DeferredElementNSImpl" class with the name "TestPart" - which on inspection contains a child element "message" containing the expected "Hello World" string.
(I attach the relevant part of the WSDL at the bottom)


When we switch to using the Tuscany ProcessConfImpl - with its "transient" setting, when we invoke the same process, we get back a different type of object - an "ElementImpl" named "TestPart". This contains an ElementNSImpl object named "hello" containing a TextImpl child holding "Hello World". This structural layout is clearly different to the previous case - and is wrong - it isn't what is expected.

Can anyone explain the difference in the two cases?  Any assistance gratefully 
received.

Is it perhaps due to differences in the compilation of the process? Or is the process treated in some very different way when it is transient?



Yours,  Mike Edwards.
-----------------------------------------
Relevant WSDL sections:

    <wsdl:types>
        <schema elementFormDefault="qualified"
           
targetNamespace="http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl";
           xmlns="http://www.w3.org/2001/XMLSchema";>

            <element name="hello">
                <complexType>
                    <sequence>
                        <element name="message" type="xsd:string"/>
                    </sequence>
                </complexType>
            </element>
        </schema>
    </wsdl:types>

    <wsdl:message name="HelloMessage">
        <wsdl:part element="tns:hello" name="TestPart"/>
    </wsdl:message>

    <wsdl:portType name="HelloPortType">
        <wsdl:operation name="hello">
            <wsdl:input message="tns:HelloMessage" name="TestIn"/>
            <wsdl:output message="tns:HelloMessage" name="TestOut"/>
        </wsdl:operation>
    </wsdl:portType>

   <plnk:partnerLinkType name="HelloPartnerLinkType">
       <plnk:role name="me" portType="tns:HelloPortType"/>
       <plnk:role name="you" portType="tns:HelloPortType"/>
   </plnk:partnerLinkType>
---------------------------------------
Relevant BPEL section:

<process name="HelloWorld"
    
targetNamespace="http://tuscany.apache.org/implementation/bpel/example/helloworld";
    xmlns:bpws="http://schemas.xmlsoap.org/ws/2004/03/business-process/";
    xmlns="http://schemas.xmlsoap.org/ws/2004/03/business-process/";
    xmlns:tns="http://tuscany.apache.org/implementation/bpel/example/helloworld";
    xmlns:xsd="http://www.w3.org/2001/XMLSchema";
    
xmlns:test="http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl";
    queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
    expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">

  <import location="helloworld.wsdl" 
importType="http://schemas.xmlsoap.org/wsdl/";
     
namespace="http://tuscany.apache.org/implementation/bpel/example/helloworld.wsdl"/>

   <partnerLinks>
      <partnerLink name="helloPartnerLink" partnerLinkType="test:HelloPartnerLinkType" 
myRole="me" />
   </partnerLinks>

   <variables>
     <variable name="myVar" messageType="test:HelloMessage"/>
     <variable name="tmpVar" type="xsd:string"/>
   </variables>

   <sequence>
       <receive
          name="start"
          partnerLink="helloPartnerLink"
          portType="test:HelloPortType"
          operation="hello"
          variable="myVar"
          createInstance="yes"/>

      <assign name="assign1">
          <copy>
              <from variable="myVar" part="TestPart"/>
              <to variable="tmpVar"/>
          </copy>
          <copy>
              <from>concat($tmpVar,' World')</from>
              <to variable="myVar" part="TestPart"/>
          </copy>
      </assign>
       <reply name="end"
              partnerLink="helloPartnerLink"
              portType="test:HelloPortType"
              operation="hello"
              variable="myVar"/>
   </sequence>
</process>

Reply via email to