![]() |
|
Just another Perl shrine | |
PerlMonks |
comment on |
( #3333=superdoc: print w/replies, xml ) | Need Help?? |
In the beginning I tried creating objects (bless {...}) and pass them to SOAP to create the xml-message, but this didn't worked well. Most of the times it created SOAP-xml that wasn't what the other side expected i.e. it was useless.SOAP::Lite has absorbed some but not all functionality from SOAP::WSDL. If you want to send objects (complexTypes) to a SOAP web-service use SOAP::WSDL. It works. Really. Hand-building XML for SOAP (even using templates) is just a waste of time. That's what WSDL is for. The only conceivably non-useless scenario I can think of for partially building SOAP messages with templates is the case where the web-service expects Document/Literal (or .NET) encoding, but at the same time allows for recursively defined complexTypes to be passed. That's quite a lot more complicated than what most developers have to deal with. Everyone should know that "SOAP Interoperability" is a cosmic-scale joke perpetrated on the industry by hermit-like evil geniuses. That being said, it's still much better to use SOAP::WSDL and to override its default behaviour where necessary. If you find you're using set of overrides a lot, create a sub-class of SOAP::WSDL. Simple.
The bad thing about this approach is that you have to read .wsdl and .xsd specs :( arggh..If you've gone down this path because SOAP::Lite / SOAP::WSDL don't yet implement the WSDL 'import' construct... that's a little drastic :-) You have a few options:
-David In reply to Re^2: Starting on SOAP
by erroneousBollock
|
|