ode-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonathan Coogan" <Jonathan.Coo...@Attachmate.com>
Subject RE: Inline variable initialization in Ode 1.3.2
Date Wed, 08 Jul 2009 23:12:40 GMT
Hi Bill.  Good suggestion.  Even when I echo the inline initialized
variable back to the response it does not work.  I created a simpler
example that uses an initialized variable of type string.  When I assign
to to the response I get an AssignmentFault saying that the variable is
uninitialized.

---------- Begin TestInlineInitialization2.wsdl ---------- 
<?xml version="1.0"?>
<definitions name="TestInlineInitialization2"
        targetNamespace="mynamespace"
        xmlns:tns="mynamespace"
        xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
        xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
        xmlns="http://schemas.xmlsoap.org/wsdl/"
        >

    <types>
        <schema attributeFormDefault="unqualified"
elementFormDefault="qualified" 
                targetNamespace="mynamespace" 
                xmlns="http://www.w3.org/2001/XMLSchema">

            <element name="Input" type="string" />
            <element name="Output" type="string" />
        </schema>
    </types>

    <message name="InputMessage">
        <part name="payload" element="tns:Input"/>
    </message>
    <message name="OutputMessage">
        <part name="payload" element="tns:Output"/>
    </message>

    <portType name="ServicePortType">
        <operation name="process">
            <input  message="tns:InputMessage" />
            <output message="tns:OutputMessage"/>
        </operation>
    </portType>
     
    <plnk:partnerLinkType name="ServicePartnerLinkType">
        <plnk:role name="ServiceProvider"
portType="tns:ServicePortType"/>
    </plnk:partnerLinkType>
    
    <binding name="ServiceBinding" type="tns:ServicePortType">
      <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
      <operation name="process">
        <soap:operation soapAction="mynamespace/process" />
        <input>
          <soap:body use="literal" />
        </input>
        <output>
          <soap:body use="literal" />
        </output>
      </operation>
    </binding>
    
    <service name="TestInlineInitialization2Service">
        <port name="TestInlineInitialization2Port"
binding="tns:ServiceBinding">
          <soap:address
location="http://[server]:[port]/processes/TestInlineInitialization2" />
        </port>
    </service>
</definitions>
---------- End TestInlineInitialization2.wsdl ----------


---------- Begin TestInlineInitialization2.bpel ----------
<?xml version="1.0" encoding="UTF-8"?>
<bpel:process exitOnStandardFault="yes"
    expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
    name="TestInlineInitialization2"
    queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
    suppressJoinFailure="yes" targetNamespace="mynamespace"
 
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
 
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
    xmlns:ode="http://www.apache.org/ode/type/extension"
    xmlns:tns="mynamespace" xmlns:xs="http://www.w3.org/2001/XMLSchema">
    <bpel:import importType="http://schemas.xmlsoap.org/wsdl/"
        location="TestInlineInitialization2.wsdl"
namespace="mynamespace"/>
    <bpel:partnerLinks>
        <bpel:partnerLink myRole="ServiceProvider" name="client"
partnerLinkType="tns:ServicePartnerLinkType"/>
    </bpel:partnerLinks>
    <bpel:variables>
        <bpel:variable messageType="tns:InputMessage" name="input"/>
        <bpel:variable messageType="tns:OutputMessage" name="output"/>
        <bpel:variable name="StringVariable" type="xs:string">
          <bpel:from>
            <bpel:literal>Value</bpel:literal>
          </bpel:from>
        </bpel:variable>
    </bpel:variables>
    <bpel:sequence name="process">
        <bpel:receive createInstance="yes" name="ReceiveInput"
            operation="process" partnerLink="client"
            portType="tns:ServicePortType" variable="input"/>
        <bpel:assign name="Assign" validate="no">
            <bpel:copy>
                <bpel:from variable="StringVariable"/>
                <bpel:to part="payload" variable="output"/>
            </bpel:copy>
        </bpel:assign>
        <bpel:reply name="ReplyWithOutput" operation="process"
            partnerLink="client" portType="tns:ServicePortType"
variable="output"/>
    </bpel:sequence>
</bpel:process>
---------- Begin TestInlineInitialization2.bpel ----------

Here is the fault I get:

INFO  [ASSIGN]: Assignment Fault:
{http://docs.oasis-open.org/wsbpel/2.0/process/executable}uninitializedV
ariable,lineNo=30,faultExplanation=The variable StringVariable isn't
properly initialized.

-----Original Message-----
From: Bill McCusker [mailto:wmccusker@parasoft.com] 
Sent: Wednesday, July 08, 2009 2:45 PM
To: user@ode.apache.org
Subject: Re: Inline variable initialization in Ode 1.3.2

Hi Jonathan,

    The inline initialization looks fine in regard to the spec. A
selectionFailure could also come from a problem with the query used in
the assign. If you just echo the inline initialized variable back to the
response does the expected structure get returned? If so then the
problem is the query used in the assign.

Bill McCusker

Jonathan Coogan wrote:
> Hello again.  I have a question about using the inline from-spec for 
> variable initialization 
> (http://cwiki.apache.org/confluence/display/ODExSITE/WS-BPEL+2.0+Speci
> fi
> cation+Compliance#WS-BPEL2.0SpecificationCompliance-Initialization).
>  
> It's not working for me and I was hoping someone could tell me if I'm 
> doing something wrong.  Here is a very simple example in which I try 
> to assign data to and from a variable that has an inline initializer.

> I get a selectionFailure at runtime.
>  
>
>   


Mime
View raw message