Ive got a SOAP server running, and Im trying to assess the performance impacts of making the Listen queue really big, and letting requests pile up there.

The client is a java program that I expect to be quite bursty in its traffic profile - long stretches of boredom (no requests), punctuated by sheer panic (a flood of them). The client may use many threads to send the reqs.

Id prefer that they wait synchronously on the replies; acks and delayed callbacks seem like protocol complexity and overkill, but this is subject to system-wide performance estimates.

Im thinking that this will be the light-weight approach.

$daemon = SOAP::Transport::HTTP::Daemon
	-> new ( LocalAddr => $gwcf->{soap_host},
		 LocalPort => $gwcf->{soap_port},
		 Listen    => $gwcf->{soap_listen_queue} || 5,
		 ReuseAddr => 1 )
	-> dispatch_to ('GwApi', 'TryMe');
FWIW (and this is pretty cool), the code after this forks a bunch of times, (after the Listener socket is bound), and each slave-server process accepts requests as available. So this is really a IO::Socket::INET question, despite the SOAP::Lite layer Im using (thx & kudos to Pavel Kulchenko, Kieth Brown, DevelopMentor)

The work-load is basically self-balancing, and appears to be as light as it can get :-) This is the case on LINUX AND ON SUNOS 5.8.

The only downside is that its hard to tell what the work-load is, and whether (for instance) new slave-servers should be spawned to help out.

Im aware of NET::Server::PreFork, but it doesnt appear to do anything more fancy than restart slaves that have exited. I dont want to use timestamps in the SOAP requests, that would expose the server to stupid time-of-day tricks.

So I seek sufficient Network/Sockets Fu to be able to win the perl vs java arguments that may be in my future. tia


In reply to how to find out whats in a LISTEN queue by jimc

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.