Squeak networking (was "UDP for Win32 Squeak")

Bijan Parsia bparsia at email.unc.edu
Wed Jul 14 19:31:39 UTC 1999


At 2:43 PM -0400 7/14/99, Ralph Johnson wrote:

>The particular problem that bit us was that our server would lose
>connection attempts.  If there were two attempts to make a connection
>that were very close together, the second one would be lost.  We
>still run a swiki, and live with its less than stellar performance,
>but we quit trying to fix the problem once we realized it would
>require redoing the whole networking system.
>
>-Ralph

IIRC, this is a consequence of the non-BSD socket semantics promulgated by
the original Mac implementation. (I believe that current Mac networking is
cool wrt this issue, and, even if not in the standard system (which I would
find very hard to believe) I think there is some very good socket code
floating about as a drop in library.)

I do second the need to redo the networking code, and IMHO it should be a
fairly high priorty item, as many folks (currently) get introduced to
Squeak via PWS and the Swikis and for them not *just* to be pokey, but
bizarrely unreliable (and having spent many, many non-expert hours trying
to find, much less fix, these problems, I tesify that it's bizarre ;)) is a
Very Bad Thing.

And the solution seems to be at hand with the correspondents framework. I
see three possible impediments to it's wholesale, rapid adoption:

	1) It requires new primatives and these must be ported. Currently, they
are available only (I believe) for Windows. Of course, it's absolutely the
case that the current primatives must be replaced anyway. However, it might
be wiser to make them pluggable. Craig, are there extensive barriers to
doing this?
	2) The framework is dependant on Craig's exception and streams
frameworks. ("Exception-handling is used in many places...") So, adoption
of Correspondence entails adoption of these as well. If one has
reservations about them (either for backward compatibility reasons, or
wanting a different approach to these issues reasons, or...) then that will
be a barrier to poping in Correspondents.
	3) This may be a moot issue, but the doc on Craig's website says: "The
exception-handling framework requires scope-aware closures to work
properly." I don't know how this affects use of Correspondents, but if it's
a problem then wholesale adoption of Correspondents must wait upon the
requisite VM modifications.

I believe this correctly summerizes the issues involved. One crucial point
reemphasized: the current socket code is (at least, for servers) very very
very broken at a fundemental level. It *cannot*, AFAICT, be fixed; it must
be replaced. (I'll also note that fixing some things leads to bizarre
problems elsewhere: Right now, in greater than 2.1 image/vm PWS servers,
*some* people experience massive slowdowns in both servering and UI. This
occurs *idiosyncratically* on all sorts of configurations and platforms,
and it's a real problem to moving to 2.4 based Swikis. I *believe* this
problem is due to a fix of a *separate* problem in listenLoop, but can't
confirm it.)


I'd like to see a strategy for dealing with this. I'm up for helping with
coordination, feedback, testing, whatever :)

Oh, the Correspondents overview is at:
	<http://netjam.org/self/projects/smalltalk/correspondents.html>

Cheers,
Bijan Parsia





More information about the Squeak-dev mailing list