Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

Re: SOAP WSDL and perl

by jhourcle (Prior)
on Apr 08, 2009 at 17:22 UTC ( #756393=note: print w/replies, xml ) Need Help??

in reply to SOAP WSDL and perl

From your comment about saving it as a CGI file, I suspect that you're running into the same problem as Webservices and browsers

Replies are listed 'Best First'.
Re^2: SOAP WSDL and perl
by secura (Initiate) on Nov 11, 2009 at 12:17 UTC
    I am running a local StockQuoteService , http://localhost:8080/axis2/services/StockQuoteService?wsdl
    $stockprice=SOAP::Lite ->service('http://localhost:8080/axis2/service/StockQuoteService?w +sdl') ->getPrice('IBM'); print Dumper($stockprice);
    The result returns $VAR1 = undef; I am getting a undef value , what is the correct way to call a webservice using Perl?
      I usually use this:

      #!/usr/bin/perl use strict; use warnings; use Data::Dumper; use SOAP::Lite; use SOAP::WSDL; my $service = SOAP::Lite ->service('http://localhost:8080/axis2/service/StockQuoteSer +vice?wsdl'); print Dumper "IBM ", $service->getQuote('IBM'), "\n";
        The URL you have I guess is wrong. It is "services" not "service". When I run the code with URL I get the following SOAP message returned
        <?xml version='1.0' encoding='utf-8'?><soapenv:Envelope xmlns:soapenv= +""><soapenv:Header xmlns:wsa +=""><wsa:Action> +/2005/08/addressing/soap/fault</wsa:Action></soapenv:Header><soapenv: +Body><soapenv:Fault><faultcode>VersionMismatch</faultcode><faultstrin +g>Only SOAP 1.1 or SOAP 1.2 messages are supported in the system</fau +ltstring><detail /></soapenv:Fault></soapenv:Body></soapenv:Envelope>
        What could be the error?

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://756393]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2018-05-25 03:48 GMT
Find Nodes?
    Voting Booth?