AFAIK, bpe does not support that literals :(
You should stick with expressions...
Hopefully, we will have a more powerful bpel engine when Apache Ode will be
available.
Cheers,
Guillaume Nodet
On 6/22/06, helloworld <[EMAIL PROTECTED]> wrote:
Thanks for your help, I really appreciate it. Unfortunately the problem
(most likely me) is still there.
In your last mail you asked, "Did you ensure that your xml can be
validated
with the needed xsd schema ? "
If you mean that I should reference the xsd from the BPEL file, yes I have
done it with the following import:
<bpws:import location="../Connection.wsdl"
namespace="http://www.hp.com/xsd/"
importType="http://www.w3.org/2001/XMLSchema/">
</bpws:import>
If you meant something else, then no, I have not done it.
You also recommended a BPEL designer. I have also used various BPEL
designers, like Active Endpoints and Cape Clear, to help generate my BPEL
code. I tried eclipse, but unfortunately I couldn't get it to work yet.
The BPEL that was generated by both Cape Clear and Active Endpoints showed
me that the format for a literal assignment in my copy statement for what
I
want to do should look like the following:
<bpws:copy>
<bpws:from><ns2:ConnectResponse><ns2:output>Test</ns2:output></ns2:ConnectResponse></bpws:from>
<bpws:to variable="ConnectResponse" part="ConnectResponse"/>
</bpws:copy>
My current situation is as follows:
When I do not have the above copy statement in my Bpel code, the bare
bones
bpel code runs smoothly through the process of a receive, assignment of an
"expression" (not a literal), and a reply. When the above copy statement
is
added, I get the BPELSAXException.
Don't know if you need it, but I will include the BPEL and WSDL below.
Thank you very much for your help.
Phil
<?xml version="1.0"?>
<bpws:process name="ServicemixBpelProcess"
targetNamespace="http://www.hp.com/ServicemixBpelProcess"
xmlns:tns="http://www.hp.com/ServicemixBpelProcess"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:bpws="
http://schemas.xmlsoap.org/ws/2003/03/business-process/"
xmlns:ns1="http://www.hp.com/wsdl/"
xmlns:ns="http://www.hpPartnerLinks.wsdl"
xmlns:ns2="http://www.hp.com/xsd/">
<bpws:import location="../ConnectionPartnerLinks.wsdl"
namespace="http://www.hpPartnerLinks.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/">
</bpws:import>
<bpws:import location="../Connection.wsdl"
namespace="http://www.hp.com/xsd/"
importType="http://www.w3.org/2001/XMLSchema/">
</bpws:import>
<bpws:partnerLinks>
<bpws:partnerLink myRole="Connector"
name="ConnectionServicePartnerLink"
partnerLinkType="ns:ConnectionServicePartnerLink">
</bpws:partnerLink>
</bpws:partnerLinks>
<bpws:variables>
<bpws:variable name="Connection"
messageType="ns1:Connection"/>
<bpws:variable name="ConnectResponse"
messageType="ns1:ConnectResponse"/>
</bpws:variables>
<bpws:faultHandlers></bpws:faultHandlers>
<bpws:eventHandlers></bpws:eventHandlers>
<bpws:sequence>
<bpws:receive partnerLink="ConnectionServicePartnerLink"
portType="ns1:IConnection" operation="Connect"
variable="Connection"
createInstance="yes">
</bpws:receive>
<bpws:assign>
<bpws:copy>
<bpws:from><ns2:ConnectResponse><ns2:output>Test</ns2:output></ns2:ConnectResponse></bpws:from>
<bpws:to variable="ConnectResponse"
part="ConnectResponse"/>
</bpws:copy>
<bpws:copy>
<bpws:from expression="'This is a generic
response'"/>
<bpws:to variable="ConnectResponse"
part="ConnectResponse"
query="/ns2:ConnectResponse/ns2:output"/>
</bpws:copy>
</bpws:assign>
<bpws:reply partnerLink="ConnectionServicePartnerLink"
portType="ns1:IConnection" operation="Connect"
variable="ConnectResponse">
</bpws:reply>
</bpws:sequence>
</bpws:process>
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions name="Connection"
targetNamespace="http://www.hp.com/wsdl/"
xmlns:tns="http://www.hp.com/wsdl/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:xsd1="http://www.hp.com/xsd/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<wsdl:types>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
attributeFormDefault="unqualified" elementFormDefault="qualified"
targetNamespace="http://www.hp.com/xsd/" xmlns:tns="http://www.hp.com/xsd/
">
<xsd:element name="Connection">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="input" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="ConnectResponse">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="output" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
</wsdl:types>
<wsdl:message name="Connection">
<wsdl:part name="Connection" type="xsd1:Connection"/>
</wsdl:message>
<wsdl:message name="ConnectResponse">
<wsdl:part name="ConnectResponse" type="xsd1:ConnectResponse"/>
</wsdl:message>
<wsdl:portType name="IConnection">
<wsdl:operation name="Connect">
<wsdl:input message="tns:Connection"/>
<wsdl:output message="tns:ConnectResponse"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="IConnectionBinding" type="tns:IConnection">
<soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="Connect">
<soap:operation soapAction=""/>
<wsdl:input>
<soap:body use="literal"/>
</wsdl:input>
<wsdl:output>
<soap:body use="literal"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="ConnectionService">
<wsdl:port name="IConnection" binding="tns:IConnectionBinding">
<soap:address location="http://localhost:8080/ccx/Connection"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
--
View this message in context:
http://www.nabble.com/BPEL%3A-How-to-assign-a-literal-t1829382.html#a4995720
Sent from the ServiceMix - User forum at Nabble.com.