Perl-LWP is way cool!

I've built maybe a dozen gizmos that cruise around various websites, some with SSL secure logins, etc. Some sites have bogus search engines and I just have to suck their database dry by navigating through their webpages, generating 10's of thousands of requests via their bogus search engine.

I would caution you about overwhelming the other guy. It is possible for you to be "blacklisted" if you generate too much traffic too fast on a site.

The thread model is the very most complex thing that you can do, but it is the highest performance. The fork() model is slower but not by much. Instead of a multi-thread process, that whacks the doo-doo out of a site, as fast as you can, maybe run 10 processes at a more "leisurely" pace that beats on 10 sites at once.

Update:Got some down votes on this post...I'll try a clarification...the main idea is not use the most complex multi-processing model when something easier will do and second depending upon what kind of site you are accessing, how many times per second you do that makes a difference. Some my LWP programs access some sites that are "small" in terms of bandwidth and processing power but have significant size DB's. I can't crash Google.com with a single machine, but on some "small" sites, too fast a flood of requests can be "disruptive" to say the least. I'm just saying to be a "good citizen" out there on the web. Don't unleash a maximally performant web query engine on a website that can't take it. I think this is just common courtesy and is something to be considered.


In reply to Re^3: how to add threads in the script by Marshall
in thread Threads problem with Tk by go0913

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.