Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

SOAP::Lite, WSDL , and firewall

by perlTM (Initiate)
on May 21, 2010 at 14:52 UTC ( [id://841105]=perlquestion: print w/replies, xml ) Need Help??

perlTM has asked for the wisdom of the Perl Monks concerning the following question:

Hi. Is there a option to declare the firewall exception in a SOAP::Lite web service request using a wsdl file? Normally you would write and process:
use SOAP::Lite ;
...
@result = SOAP::Lite
-> service('http://a.particular.file/wsdl')
-> $method ( @arguments ) ;
print join ( "\n", @result ) . "\n" ;
Are there some arguments to the object to specify our own proxy and the port (in PHP PEAR is such an option - but Perl is my language)? Thanks in advance ...

Replies are listed 'Best First'.
Re: SOAP::Lite, WSDL , and firewall
by ikegami (Patriarch) on May 21, 2010 at 16:13 UTC
    I believe SOAP::Lite uses LWP, in which case you can configure a proxy as you would for LWP. I think it can be done via environment variables. See LWP::UserAgent. Sorry, it's all I have time for right now.
Re: SOAP::Lite, WSDL , and firewall
by Corion (Patriarch) on May 21, 2010 at 16:13 UTC
Re: SOAP::Lite, WSDL , and firewall
by Khen1950fx (Canon) on May 22, 2010 at 01:41 UTC
    To specify a proxy and port, I'd do something like this:
    #!/usr/bin/perl use strict; use warnings; use SOAP::Lite; print SOAP::Lite -> uri('http://www.soaplite.com/Demo') -> proxy('http://services.soaplite.com/hibye.cgi') -> hi() -> result; my $soap = SOAP::Lite->proxy( 'http://user:password@endpoint.server:80/', proxy => ['http' => 'http://my.proxy.server/']);
      and, in addition, do you think that

      my $soap = SOAP::Lite->service( 'http://user:password@endpoint.some.server:80/wsdl',
      proxy => 'http' => 'http://my.proxy.server/' );


      would work ?
        No, it won't work because you're mixing the service proxy and your local server proxy together. Maybe you could post some code to show us how you're using your service?
      Hi Khen1950fx,

      this kind of client (->proxy() ->uri() ) I already found in the plenty descriptions in the web.

      The point is to use an WSDL (by ->service(http://*.wsdl) ) and to use at the same time an object that specifies a proxy server AT MY OWN SIDE, eventually an own port, too.

      Kind regs
        o use at the same time an object that specifies a proxy server AT MY OWN SIDE, eventually an own port, too.

        Are you talking about a local proxy which provides you with an internet connection? For that just set enviromental variable HTTP_Proxy

        3231: $self->useragent->env_proxy if $ENV{'HTTP_proxy'};
Re: SOAP::Lite, WSDL , and firewall
by Anonymous Monk on May 21, 2010 at 15:37 UTC

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://841105]
Approved by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (3)
As of 2024-04-20 02:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found