Odi's astoundingly incomplete notes

New entries | Code

Don't generate WSDL

The whole world, please stop generating WSDLs! It's bollocks.

A WSDL file is an interoperability document. Other applications depend on it. For this reason its content must be fully under your control. The exact content of this file must not depend on some half-baked decision of some stupid WSDL generator that doesn't know what it's doing.

The real world out there is unfortunately as full of bad WSDL code generators as it is full of broken WSDL interpreters. Some do not properly support different namespaces. Some only accept a single embedded schema. Of course most only support SOAP binding. Some expect certain namespace prefixes etc. The bugs and madnesses are endless. So you must be able to tweak this file to work around certain interoperability issues. Sometimes even the users of your service may have to pre-process the WSDL with an XSLT transformation to accomodate for certain bugs. Use your favourite WSDL edtior. But be prepared to make manual changes in the XML file if necessary.

At the same time, be careful to be pragmatic about which WS features you use. The fancier stuff you do the more problems you will have to face.

posted on 2008-06-16 17:47 UTC in Code | 0 comments | permalink