From: Kevin Collins on
On 2010-02-02, C.DeRykus <derykus(a)gmail.com> wrote:
> On Feb 2, 2:26�am, Salvador Fandino <sfand...(a)yahoo.com> wrote:
>> C.DeRykus wrote:
>> > On Feb 1, 1:47 pm, Kevin Collins <spamtotr...(a)toomuchfiction.com>
>> > wrote:
>> >> Hi,
>>
>> >> � � � � I have a perl script running to query a SOAP process, but using a basic
>> >> Net::HTTPS connection. If the server takes more than 60 econds to respond, the
>> >> script fails with the following error:
>>
>> >> SSL read timeout: �at /opt/CTperl-5.8.4/lib/site_perl/5.8.4/Net/HTTP/Methods.pm
>> >> line 226 Net::SSL::die_with_error('Net::HTTPS=GLOB(0x60000000000608a0)', 'SSL
>> >> read timeout') called at
>> >> /opt/CTperl-5.8.4/lib/site_perl/5.8.4/IA64.ARCHREV_0-LP64/Net/SSL.pm line 218
>> >> ...
>> >> ...
>>
>> >> My invocation looks like this:
>>
>> >> �my $connection = Net::HTTPS->new(Host => $Server, timeout => 300) || die $@;
>>
>> try using "Timeout" instead!
>>
>
> You're right. Net::HTTP/Net::HTTPS inherit from IO::Socket::INET
> which specifies only an uppercase "Timeout" option.
>
> perl -MNet::HTTPS -wle "$c=Net::HTTPS->new(Timeout=>10);
> print $c->timeout"
> 10

Thanks, guys! I had found Timeout, but tried to invoke it as:

$connection->Timeout(300);

but that did not work. I never thought to pass it as an option! That did the
trick...

Thanks,

Kevin