[Twisted-Python] What rough protocol, its hour come at last, slouches towards Austin to be born?
Allen Short
washort at twistedmatrix.com
Tue Apr 9 07:29:34 MDT 2002
On Mon, 08 Apr 2002, Glyph Lefkowitz did violence to a keyboard thusly:
> I just checked in a substantial refactoring and change to Jelly,
> finalizing what I think Jelly ought to look like in PB's wire protocol.
> Before I declare that it is well and truly standard, however, there are
> a few things I'd like to resolve, and I'd be interested to hear a few
> opinions on them...
>
> 1: use of the word "tuple".
>
> Jelly uses the word "tuple" on the wire, which is fairly
> Python-specific. Really it ought to be "immutable-list" or something
> similar (perhaps leaving the door open for more immutable types in the
> future?). Thoughts on this, especially from implementors in other
> languages?
More immutable types would be nice, yes. (Oz, for example, has 'records'
which in effect are immutable dicts.) I dont know if there's any
advantage to making 'immutable' a separate protocol element or if such
data structures should just be identified as such in their name.... for
that matter. 'tuple' isn't the worst thing you could call it -- i dont
think jelly would suffer from being called unabashedly python-centric.
:)
> 2: jellying of arguments/kwargs
> A couple of possible small improvements come to mind:
> * provide alternate forms of proto_message which alternatively do or
> do not send arguments, keyword args, or either
To my mind, this seems the cleanest way to solve it.
> 4: always assume exactly one reference
>
> some work is probably wasted right now in maintaining distributed
> reference counts; the peer really only cares whether the other side has
> a reference or it doesn't. The one place that this is a little weird is
> the decache/uncache handshake.
well, my opinion on enforcing single referece counts has been expressed
before :) this would be quite nice but i'm unsure how it would interact
with Python semantics... would jelly refuse to send refs to objects that
it had already sent?
--
Allen Short Programmer-Archaeologist
washort at twistedmatrix.com
"optimization is hacker crack. " -- Johan Kullstam, c.l.l
More information about the Twisted-Python
mailing list