ode-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Wenfeng ZHAO" <zhaowenf...@gmail.com>
Subject Re: problem invoking a real java webservice
Date Wed, 23 Sep 2009 14:35:02 GMT
Hello ytrewq2002\,

	Are you sure what the invoked java service returned is "Hello pippo" rather than "pipo"?
 See the record:

14:28:42,875 DEBUG [ASSIGN] ASSIGN Writing variable 'Out' value '<?xml version="1.0" encoding="UTF-8"?>
<message><parameters><helloResponse xmlns="http://hello.netbureau.it/">
                            <myxsd:return xmlns:myxsd="http://hello.netbureau.it/">pippo</myxsd:return>
                        </helloResponse></parameters></message>'


Regards,
Wenfeng


=======On 2009-09-23 at 21:23:49 ytrewq2002\ wrote: =======

>hi,
>
>i want to call a webservice HelloWs using the <invoke> bpel statment
>I have a process Caller.bpel that receive a soap message from a client (a coplex type
with string called name)
>It copies this string to input variable and invoke the webservices passing this variable.
The webservice take
>the string "name" and return a string "Hello" + name, where name is the content of string
passed.
>The output of invoke is passed to the <reply>
>
>Why i passed name="pippo" and the reply give to me "pippo"?? that is wrong because The
invoke has to call the 
>web service and copy the output's variable value into the reply variable and the result
would be "Hello pippo"
>(not pippo!!**)
>why doesn't work?
>
>this is the bpel process (i attached as ascii text file the ode's log)
>
>help please, give me an advice, thank you
>
>here is the bpel:
>
>
><process
>    name="Caller"
>    targetNamespace="http://MyTest.com/Test"
>    xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
>    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
>    xmlns:sxt="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Trace" 
>    xmlns:sxed="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Editor"
>    xmlns:tns="http://MyTest.com/Test"
>    xmlns:wshello="http://wsdl.hello.netbureau.it/"
>    xmlns:myxsd="http://hello.netbureau.it/"
>    >
>     <!-- wsdl Caller + partnerLink defintion-->
>    <import namespace="http://MyTest.com/Test" location="Caller.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
>     <!-- wsdl Ws Helloname + PartenrLinkType definition-->
>    <import namespace="http://wsdl.hello.netbureau.it/" location="Helloname.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
>    <!-- xsd xhema for HellonameWs -->
>    <import namespace="http://hello.netbureau.it/" location="Helloname.xsd_1.xsd" importType="http://www.w3.org/2001/XMLSchema"/>
>    <partnerLinks>
>        <partnerLink name="HelloWs" partnerLinkType="wshello:Helloname" partnerRole="WriteHelloMsgRole"/>
>        <partnerLink name="Caller" partnerLinkType="tns:Caller" myRole="CallerProvider"/>
>    </partnerLinks>
>    <variables>
>        <variable name="CallerOut" messageType="tns:CallerResponseMessage"/>
>        <variable name="HelloOut" messageType="wshello:helloResponse"/>
>        <variable name="HelloIn" messageType="wshello:hello"/>
>        <variable name="ProcessIn" messageType="tns:CallerRequestMessage"/>
>    </variables>
>    <sequence>
>        <receive name="ReceiveFromclient"
>        createInstance="yes"
>        partnerLink="Caller"
>        operation="process" xmlns:tns="http://MyTest.com/Test"
>        portType="tns:Caller"
>        variable="ProcessIn"/>
>        <assign name="Assign1">
>            <copy>
>                <from>
>                    <literal>
>                        <wshello:hello>
>                            <myxsd:name/>
>                        </wshello:hello>
>                    </literal>
>                </from>
>                <to variable="HelloIn" part="parameters"></to>
>            </copy>
>            <copy>
>                <from>$ProcessIn.payload/tns:input</from>
>                <to>$HelloIn.parameters/myxsd:name</to>
>            </copy>
>        </assign>
>        <invoke name="InvokeHelloname"
>        partnerLink="HelloWs"
>        operation="hello"
>        portType="wshello:Helloname"
>        inputVariable="HelloIn"
>        outputVariable="HelloOut"/>
>        <assign name="Assign2">
>        <copy>
>                <from>
>                    <literal>
>                        <tns:CallerResponse>
>                            <tns:result/>
>                        </tns:CallerResponse>
>                    </literal>
>                </from>
>                <to part="payload" variable="CallerOut"/>
>            </copy>
>            <copy>
>                <from>$HelloOut.parameters/myxsd:return</from>
>                <to>$CallerOut.payload/tns:result</to>
>            </copy>
>        </assign>
>        <reply name="ReplyToClient" partnerLink="Caller" operation="process" portType="tns:Caller"
variable="CallerOut"/>
>    </sequence>
>   
></process>
>
>
>
>deploy.xml:
>
><deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
>	xmlns:pns="http://MyTest.com/Test"
>	xmlns:wns="http://wsdl.hello.netbureau.it/"
>    xmlns:schemaLocation = "deploySchema.xsd">
>
>	<process name="pns:Caller">
>		<active>true</active>
>		<provide partnerLink="Caller">
>			<service name="pns:CallerService" port="CallerPort"/>
>		</provide>
>        <invoke partnerLink="HelloWs">
>            <service name="wns:HellonameService" port="HellonamePort"/>
>        </invoke>
>	</process>
></deploy>

= = = = = = = = = = = = = = = = = = = =
ZHAO Wenfeng (赵文峰)
Ph.D. Candidate
http://www.bupt.edu.cn

Mime
View raw message