comp.lang.ada
 help / color / mirror / Atom feed
From: Dave Thompson <david.thompson1@worldnet.att.net>
Subject: Re: tasksing and TCP sockets
Date: Mon, 06 Feb 2006 05:02:16 GMT
Date: 2006-02-06T05:02:16+00:00	[thread overview]
Message-ID: <ojldu1l6m1h1e67a6k2h3h8pntir245n9s@4ax.com> (raw)
In-Reply-To: SfWdnT1feI18l0LeRVn-uw@comcast.com

On Tue, 31 Jan 2006 00:59:45 -0600, tmoran@acm.org wrote:

> >You should _not_ need delay statements. Redesign to be waiting on
> >socket completions.
>   If the allowed response latency isn't terribly short (and it doesn't
> sound like it is here) there's nothing wrong with letting the system
> buffer up input while the reading task does a delay.  Just use a blocking
> socket and poll to see if there's more input data available.  Remember
> that "waiting on socket completions" in Windows means "polling the Windows
> message loop for a socket completion message".

In Windows-the-GUI, or at least for a GUI task/thread on Windows.

But for Windows-the-OS (a non-GUI task/thread or "console" program)
plain old recv() and if you wish select() work just fine.

<snip>

<OFFTOPIC> I feel impelled to re-quote this prior line:

>   TCP server that simulates the world

I realize it makes sense in the context of the OP system description,
but just looking at it in isolation reminded me all too forcefully of
any number of past project breakdown/deliverable items with
demure-looking descriptions that turned out to be disasters. <G?> </>

- David.Thompson1 at worldnet.att.net



  parent reply	other threads:[~2006-02-06  5:02 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-30 22:12 tasksing and TCP sockets Rolf
2006-01-31  2:40 ` Stephen Leake
2006-01-31  6:59   ` tmoran
2006-01-31 23:03     ` Rolf
2006-02-01  1:26       ` Stephen Leake
2006-02-01  7:39         ` Rolf
2006-02-01 14:52           ` Stephen Leake
2006-02-03 20:33             ` Rolf
2006-02-04 12:48               ` Stephen Leake
2006-02-06  5:02     ` Dave Thompson [this message]
2006-01-31 22:52   ` Rolf
2006-02-01  1:23     ` Stephen Leake
2006-02-01 21:12       ` Simon Wright
2006-01-31  3:02 ` Steve
2006-01-31 10:09 ` Dmitry A. Kazakov
2006-01-31 21:55   ` Simon Wright
2006-02-01  8:54     ` Dmitry A. Kazakov
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox