[ 
http://issues.apache.org/jira/browse/TUSCANY-454?page=comments#action_12416706 
] 

Jervis Liu commented on TUSCANY-454:
------------------------------------

Basically what happens is that we use "service name + port name" as a unique 
key to retrieve WSDL definition from WSDL definition cache (See 
SCDLAssemblyModelLoaderImpl.java and WebServiceBindingImpl.java). When web 
service applications are hosted in a standalone web service container or any 
J2EE container, normally we can use WSDL file location URL to uniquely identify 
a web service in container, though it is also valid to use the combination of 
service name and port name as a unique key. The latter is the way how Tuscany 
uniquely identifies a web service app hosted in Tomcat. However in the case of 
Tuscany SCA demos, several demos that are deployed in Tomcat are using exact 
same wsdl files <<helloworlde4xws.patch>> <<helloworldjsclient.patch>> 
(helloworldws, helloworlde4xws and helloworldjsclient), thus same service name 
+ port name. This caused wrong wsdl defintion was retrieved from cache. 

I fixed this issue by changing those offending demos to have their own service 
name and port name in WSDL.  

Can someone kindly review and apply please. BTW, I am sorry that I have to 
provide two separate patches. For some unknown reasons, I always get an error 
message if I try to create a patch from samples directory. Thanks.



> WSDL file misloading running sca demo helloworldws
> --------------------------------------------------
>
>          Key: TUSCANY-454
>          URL: http://issues.apache.org/jira/browse/TUSCANY-454
>      Project: Tuscany
>         Type: Bug

>   Components: Java SCA Axis Binding
>     Reporter: Jervis Liu
>     Priority: Minor

>
> When I changed Tuscany sca demo helloworldws's WSDL file to include in/out 
> parameters, I found this change in WSDL is not recognized by Tuscany runtime 
> at all. How to reproduce:
> 1. Change helloworld.wsdl output message getGreetingsResponse's part element 
> from getGreetingsResponse to getGreetings
>     <wsdl:message name="getGreetingsResponse">
>         <wsdl:part element="tns:getGreetings" name="parameters"/>
>     </wsdl:message>
> 2. Run helloworldws demo, send a request from a client
> 3. Check the response from helloworldws, it still refers to 
> getGreetingsResponse element:
> <helloworld:getGreetingsResponse xmlns:helloworld="http://helloworld";>
>   <helloworld:getGreetingsReturn>Hello jervis</helloworld:getGreetingsReturn>
> </helloworld:getGreetingsResponse>
> Through debugging, I found the Binding object created for helloworldws demo 
> is actually referring to helloworlde4xws demo's WSDL file other than it's own 
> WSDL. Remove sample-helloworlde4xws and sample-helloworldjsclient directories 
> from Tomcat, everything works.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to