Question

I am using spring-ws. I think there are two ways of generating WSDL.

dynamic wsdl and static wsdl approaches.

Could you please suggest me which is better approach?

Thanks!

Was it helpful?

Solution

When it comes to the XSDs, those nice folks who created Spring-WS recommend contract-first. Their manual explains why this is the case:

http://docs.spring.io/spring-ws/site/reference/html/why-contract-first.html

... which is good enough for me.

Whether to dynamically generate the WSDL is not so much of an issue. However, in the past I have needed to generate WSDL which complies with strict corporate standards. If that is something you need to do then you should stick with static. Additionally, I have needed to tweak WSDL to ensure that the service definition plays nicely with .NET clients. Again, the only way to do that is if you have written the WSDL yourself.

Of course, if you're still learning your way around WSDL, you may find it easier to generate it initially. If you need to go static later, then can then take a copy of the generated WSDL as your starting point.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top