[ 
https://issues.apache.org/jira/browse/CXF-7398?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16069764#comment-16069764
 ] 

Christian Schneider commented on CXF-7398:
------------------------------------------

I just tested the behaviour using the demo-wsrm as well as my own simpler 
example.

I think CXF behaves as expected. The port the is implemented by the current 
service gets the correct address and the other ports remain unchanged.
The solution is to use valid dummy address urls in all ports for the wsdl. So 
tools will not complain and you can correctly use the port that is implemented.


> Invalid wsdl with multiple ports published via ?wsdl
> ----------------------------------------------------
>
>                 Key: CXF-7398
>                 URL: https://issues.apache.org/jira/browse/CXF-7398
>             Project: CXF
>          Issue Type: Bug
>          Components: WS-* Components
>    Affects Versions: 3.1.7
>            Reporter: Hadrian Zbarcea
>            Assignee: Christian Schneider
>            Priority: Minor
>
> I suspect this issue may have been reported in the past, but couldn't find 
> anything.
> I have a wsdl with a service and multiple ports. The address for each port is 
> a dummy placehoder, like {{"/port1"}}, {{"/port2}}" anyway not a regular url 
> (it's {{"greeter-exact"}} in the stack trace below). My blueprint defines 
> multiple endpoints for the different ports.
> Going in the browser at the {{http://localhost:8181/cxf/}} all the endpoints 
> are listed properly, the endpoints behave as expected. However, the wsdl(s) 
> published for each endpoint only have the address for that particular 
> endpoint/port correctly, the other ports in the services are present, but 
> with their original placeholder address (i.e. the wsdl published for each of 
> the services is different, although technically it's the same wsdl).
> The issue is that trying to create a project with tools like SoapUI results 
> in an error, see trace below, due to the invalid addresses. There is a 
> workaround, to either define a wsdl with only one port, or with multiple 
> ports, but with address placeholders that are valid http:// urls.
> Ideally the correct wsdl would be published.
> {code}
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Sending request: GET 
> /cxf/greeter-once?wsdl=META-INF/wsdl/org/apifocal/demo/greeter/greeter.wsdl 
> HTTP/1.1
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Receiving response: HTTP/1.1 200 OK
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Connection can be kept alive indefinitely
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Loading Definition...
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Loading WSDL: 
> http://localhost:8181/cxf/greeter-once?wsdl
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Returning baseInputSource 
> [http://localhost:8181/cxf/greeter-once?wsdl]
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Returning latest import URI 
> [http://localhost:8181/cxf/greeter-once?wsdl=META-INF/wsdl/org/apifocal/demo/greeter/greeter.wsdl]
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Returning latest import URI 
> [http://localhost:8181/cxf/greeter-once?wsdl=META-INF/wsdl/org/apifocal/demo/greeter/greeter.wsdl]
> Wed Jun 07 10:20:51 EDT 2017:INFO:Loading schema types from 
> [http://localhost:8181/cxf/greeter-once?wsdl]
> Wed Jun 07 10:20:51 EDT 2017:INFO:Getting schema 
> http://localhost:8181/cxf/greeter-once?wsdl
> Wed Jun 07 10:20:51 EDT 2017:INFO:Getting schema 
> http://localhost:8181/cxf/greeter-once?wsdl=META-INF/wsdl/org/apifocal/demo/greeter/greeter.wsdl
> Wed Jun 07 10:20:51 EDT 2017:DEBUG:Loaded Definition: ok
> Wed Jun 07 10:20:51 EDT 2017:INFO:Finding importer for 
> {http://demo.apifocal.org/greeter}GreeterSOAPBinding
> Wed Jun 07 10:20:51 EDT 2017:INFO:Importing binding 
> {http://demo.apifocal.org/greeter}GreeterSOAPBinding
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing endpoint /greeter-wsrm
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing endpoint /greeter-exact
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing endpoint 
> http://localhost:8181/cxf/greeter-once
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing endpoint 
> http://example.com/SoapContext/GreeterPort
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing operation greetMe
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing operation greetMeOneWay
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing operation pingMe
> Wed Jun 07 10:20:51 EDT 2017:INFO:importing operation sayHi
> Wed Jun 07 10:21:23 EDT 2017:DEBUG:Connection closed
> Wed Jun 07 10:21:35 EDT 2017:ERROR:An error occurred 
> [com.eviware.soapui.impl.wsdl.submit.RequestTransportRegistry$MissingTransportException:
>  Missing protocol in endpoint [/greeter-exact]], see error log for details
> Wed Jun 07 10:21:40 EDT 2017:ERROR:An error occurred 
> [com.eviware.soapui.impl.wsdl.submit.RequestTransportRegistry$MissingTransportException:
>  Missing protocol in endpoint [/greeter-exact]], see error log for details
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to