[Xml-compile] ignoring an invalid xml response

Pete Groff pfg104 at gmail.com
Tue Jul 13 19:29:36 GMT 2010


I'm calling a Share Point web service and get the following error:  "error:
data for element or block starting with `Privacy' missing at {
http://microsoft.com/webservices/SharePointPortalServer/UserProfileService}=
GetUserProfileByNameResponse/GetUserProfileByNameResult/PropertyData."
In looking at the wsdl and the response in SoapUI, the service is not
returning the "Privacy" element even though it is defined as required by the
wsdl.  How can I ignore such errors in XMC.  My code:

my $transporter =3D XML::Compile::Transport::SOAPHTTP->new
    (    address =3D> $service_address,
        keep_alive =3D> 1
        );
my $http =3D $transporter->compileClient(
    action =3D> '
http://microsoft.com/webservices/SharePointPortalServer/UserProfileService/=
GetUserProfileByName
'
);
my $wsdl =3D XML::Compile::WSDL11->new("$w");

my %req;
$req{AccountName} =3D 'smith';
my $call;

$call =3D $wsdl->compileClient(
    operation =3D> 'GetUserProfileByName',
    transport =3D> $http,
    port =3D> 'UserProfileServiceSoap'
);

my ($response, $trace) =3D $call->(%req);

show_trace($response, $trace);

I see that in XMC::Schema, there is a validation flag for the compile
method, but how would I get similar behavior in the code above?

Thanks in advance,
Pete
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/xml-compile/attachments/20100713/3d=
112b13/attachment.htm


More information about the Xml-compile mailing list