WSDL input validate

Hi,

I’ve just defined a doc/lit Web Service for which I would like to have its inputs schema validated. So I got to a XSD tutorial :biggrin: and got my input schema done (constraining by length, patterns and so), created a document on wM based on that schema and then I got my WSDL created through the Developer Wiz.
When I’ve got to test it, it just doesn’t validate (I set not valid values and it doesn’t throw an exception), which I’m not sure it’s ok (I would believe I’m able to specify schema constrains on WSDLs). Am I missing something? I’m attaching the WSDL (just modified the actual IP being used and the namespace real URL used).

Thanks for your input,
Brian
example.wsdl (19.1 KB)

I recommend creating your WSDL outside of WM tools (or any other tool) using a WSDL editor like XML Spy Enterprise or the Eclipse Web Developers Toolkit (and others I’m sure as well).

Then validate your WSDL using a web services testing tool that supports the WS-I Basic Profile assertions. SoapSonar will do this as well SoapUI if you configure it correctly.

What version of IS are you using? I know that in IS 6.5 you needed to create your own statements to extract and validate the payload of a doc/lit request against the IS schema you created from the XSD. I think that IS 7.1.x does this for you, but am not sure.

Mark

Thanks Mark,

But shouldn’t the default SOAP processor validate inputs based on the schema defined within the WSDL (with or without constrains) or is it just that “it should but it doesn’t…”?
Would I have to just define the input variables and validate the constrains later on the payload extracted from the SOAP message? I’m working on a 6.1 IS version but would be migrating into a 7.1 IS version soon.

Thanks for your input,
Brian

The default soap processor performs no validation of the payloads or header elements of doc/lit soap requests.

See my samples in the “sticky” posts in this forum on how to do that in a custom soap processor.

IS 7.1.x completely overhauled web services processing. Make sure you get the latest service packs and fixes as there are many fixes for web services support in IS 7.1.1.

Mark

Thank you Mark, it’s clear for me now. I’ve just got it to work by validating after getting the payload.

And I’ll do that (look into getting the latest SP for 7.1).

Regards,
Brian