[Twisted-Python] Re: Advice sought on application evolution
Andrew Francis
andrewfr_ice at yahoo.com
Tue Mar 25 13:20:07 EDT 2008
Hi Justin:
> Too much serialization, even accidental
>serialization, trades comprehensibility for
>performance. I think that's a reasonable place
>to start: make your system easy to understand, then
>make it fast once you know what's going on.
JW>How does the saying go? "Premature optimisation is
JW>the root of all evil"?
Butler Lampson in the paper "Hints for Computer System
Design" saids "Get it right! Neither abstraction nor
simplicity is a substitute for getting it right."
I think if there is a tao of Twisted, its tenets would
be performance and getting it right.
A part of getting things right, is knowing what wrong
looks like. Both Twisted and (Stackless - what I work
with), don't dedicate much time to showing what is
definitely wrong.
>The easiest place to start learning is with code that
>looks like all the other code you've written before.
I am not sure about this approach although there is
much to be said about having a programming style that
makes you feel confident to tackle problems.
I find a good way to learn is looking at good but
simple examples that do something useful, then tinker
with them. This is the way some of my favourite
computer books work - the various
Kernighan/Richie/Plauger books, Steven's "Unix Network
Programming"
In the case of Twisted, I found the Abe Fettig book
good - I looked at webcat.py and requesthandler.py and
that gave me a start. From time to time, I also posted
on this mailing list to get little examples - very
helpful.
I also like the design patterns approach to learning:
this is the name, the situation/context, the problem,
the solution, references.
I think Twisted would benefit from this approach when
one is dealing with common situations like say "call
database from request handler" or "separate business
logic from network logic."
Cheers,
Andrew
____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping
More information about the Twisted-Python
mailing list