[Twisted-Python] Re: In Defense of Taps
glyph at twistedmatrix.com
Fri Feb 14 07:42:41 EST 2003
On 13 Feb 2003 13:24:04 -0500, Abe Fettig <abe at fettig.net> wrote:
> I'd be in the "Network protocl developer" category, I guess, although my
> on of my reasons for using Twisted is to *not* have to implement
Thanks for that bit of information: after thinking about those categories some
more, I've realized that an upcoming rewrite of the website needs to address 4
* Low-level network programmers: systems people who want to write their own
* High-level network programmers: people who want to use existing
implementations of a variety of protocols. These folks are the target
audience for PB, when other protocols fall short.
* "Web Application" programmers: these people want to use fully-finished
protocol support, largely HTTP, though some SMTP and similar. Sysadmins
also fall into this category, to some extent.
* Crazy hackers or game developers who are interested in bleeding-edge
things like Twisted Reality, Issues, and Secret Project X. (As these
things mature it will probably split into more categories.)
Obviously there's some overlap, but if you don't feel like you fit into any of
those categories I'd like to know.
> having to write another little script to start my application and run it as a
> daemon seems a lot easier than writing a TAP plugin and having to "compile" a
> new TAP every time I make a change to the code.
Yes. It'd be nice to have more integration between mktap and twistd so that
you don't actually need to output the file in development. We've been lazy
about that because it'd be tough to separate the config options.
How about extending usage.Options to recognize the '--' option the same way
xinit does, and consider the mktap script the "pass-through" for twistd, e.g.:
twistd -l nohttp.log -n -f -- web -l http.log --https 443 --path ~/my-path
Hmm. That actually looks ugly to me, but something like that.
> Once I get to the point where end users are installing my software, TAPs will
> probably become more important.
Well, it's up for download ;-), and you have had to address certain
configuration issues (hence the .ini file). I think you're reaching that point
> But when I'm just running the software myself, to debug it, I don't care
> about the features TAPs might provide. Thus in my mind it seemed makes sense
> to use the other parts of Twisted before I got into TAPs.
It sounds like we're in agreement, given your previous statement. I will also
do certain kinds of development without creating a tap plugin first, when i'm
just working with a few objects and trying to figure out how they fit together.
However, "what is appropriate for the master is not appropriate for the
apprentice" -- we're mostly talking about whether it's an applicable
introduction, not about whether it's the only way to start a Twisted app.
> Could you explain (or point to some info on) how TAPs can provide "mechanisms
> for services to communicate with each other"? I'd be interested in that.
Well, the Application object is the source of communication most of the time.
You have to know a fair amount about Twisted objects' internal structure to
take advantage of that. However, if you've got a lot of structured objects
floating around, the ability to do 'mktap manhole --append myapp-shutdown.tap'
is very helpful.
In some ways this is a more theoretical advantage than a practical one. It's a
way for multiple parties to write tools to manipulate .tap files, and a
standard way for a user to invoke them. Not many of these tools have been
written so far.
> > While I think of this as an important introductory doc, it's already the
> > 18th document in the book. In fact, it comes after "Using Dirdbm", which I
> > think may be shortchanging it a *bit* more than treating it as introductory
> > :-).
> Didn't it used to be right at the front? I remember it as being one of the
> first things I read. Actually, the current HOWTO layout looks like it's
> gotten a lot better since I was last there...
It used to have a little emphasized "<--- Start Here!" next to it, which has
since been removed. I still think it's a good starting point most of the time,
even if you often forego taps. More important, though, is the consensus that we
need to build multiple indexes for different interest groups.
> I really like Twisted, thanks for all the work you guys have done!
You're welcome! It's always nice to see someone appreciating it.
| <`'> | Glyph Lefkowitz: Traveling Sorcerer |
| < _/ > | Lead Developer, the Twisted project |
| < ___/ > | http://www.twistedmatrix.com |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
Url : http://twistedmatrix.com/pipermail/twisted-python/attachments/20030214/a5328dc5/attachment.pgp
More information about the Twisted-Python