Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

missing package for web service via https?

by Anonymous Monk
on Nov 03, 2006 at 16:31 UTC ( [id://582117]=perlquestion: print w/replies, xml ) Need Help??

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

I got the following error on my work PC, but the same code does not give any error at home, so I must have installed something there before, but I cannot remember... pls help. Thanks.

500 Can't locate object method "new" via package "LWP::Protocol::https +::Socket" at d.pl line 14

Here is the code, simple:

use strict; use warnings; #use SampleService qw=>(:all); #use SOAP::Lite +trace => qw(all); use SOAP::Lite; #$ENV{HTTPS_DEBUG} = '1'; #$ENV{HTTPS_CA_FILE} = 'C:/src/perl/a.cer'; #$ENV{HTTPS_CA_DIR} = 'C:/src/perl'; my $lite = new SOAP::Lite( #uri => 'http://org.jboss.ws/samples/docstyle/bare', proxy => 'https://me:password@aseriesws.somecompany.com:8443/app/servi +ces/module?wsdl'); while (1) { my $start = time(); print"Result = " . $lite->ping()->result . ","; my $end = time(); my $diff = $end - $start; print " started at " . localtime() . ", took " . $diff . " seconds +\n"; sleep(10); }

Replies are listed 'Best First'.
Re: missing package for web service via https?
by idsfa (Vicar) on Nov 03, 2006 at 16:40 UTC

    At a guess, you're missing LWP, which contains that package (LWP::Protocol::https::Socket). Install the bundle with:

    perl -MCPAN -e 'install Bundle::LWP'

    The intelligent reader will judge for himself. Without examining the facts fully and fairly, there is no way of knowing whether vox populi is really vox dei, or merely vox asinorum. — Cyrus H. Gordon

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (4)
As of 2024-04-24 01:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found