Skip to content

JaxWsPortClientInterceptor gives errors with wsdl service names, not actual endpoints [SPR-6971] #11636

Closed
@spring-projects-issues

Description

@spring-projects-issues

Karl Palsson opened SPR-6971 and commented

the doInvoke() method on JaxWsPortClientInterceptor throws the following exception when it can't connect to the remote service...

org.springframework.remoting.RemoteAccessException: Could not access remote service at [{http://blah.namespace.company/services/more/namespace/cruft/}MyServiceSOAP]; nested exception is com.sun.xml.ws.client.ClientTransportException: HTTP transport error: java.net.ConnectException: Connection refused: connect

This is not overly helpful with working out why you get a http connect failure. Moreover, it's a fixed string. I know very well what the namespace is, I wrote the wsdl. And even if I hadn't, I know from the stack trace what service I'm calling, I don't need this in the error.

It would be much nicer if it did this instead...

org.springframework.remoting.RemoteAccessException: Could not access remote service at http://localhost:9010/webapp/services/MyService; nested exception is com.sun.xml.ws.client.ClientTransportException: HTTP transport error: java.net.ConnectException: Connection refused: connect

Where it clearly shows what it couldn't connect to.

Simply change the error building to use this.getEndpointAddress() instead of this.portQName and we'll all be much better informed, and therefore happier.


Affects: 3.0.1

Referenced from: commits eee72c5

Metadata

Metadata

Assignees

Labels

in: webIssues in web modules (web, webmvc, webflux, websocket)type: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions