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

Re: LWP::UserAgent and HUGE FILES

by bart (Canon)
on Apr 29, 2003 at 19:27 UTC ( #254064=note: print w/replies, xml ) Need Help??


in reply to LWP::UserAgent and HUGE FILES

If head() doesn't work... can't you use the callback interface? That way, you'll only read in blocks of a few k at a time, which you can then discard.

The synopsis for LWP::UserAgent says the basic syntax is

$response = $ua->request($request, \&callback, 4096);
with &callback a sub receiving the data, and 4096 the chunk size.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://254064]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (3)
As of 2019-03-24 05:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How do you Carpe diem?





    Results (114 votes). Check out past polls.

    Notices?