巨蟒扭曲: 从哪里开始

我试图开始学习创建套接字服务器扭曲。我想添加一些有用的特性(比如 auth,也许还有其他一些特性)。也许有人可以给我指出一个好的教程,这将帮助我开始(+ 也许一些其他想法)

55278 次浏览

Look here: Twisted Web in 60 seconds. That's a group of blog posts describing step by step how to do lots of common stuff with Twisted, all written by Jean-Paul Calderone, the biggest contributor of Twisted. It's really where you should start.

After that, look at the Twisted core documentation then refer to the API and then into the source code.

Have fun!

There's a great tutorial here - it's usually the one I send to new Twisty's :-)

http://krondo.com/blog/?page_id=1327

Its worth remembering that Twisted programming is more of a thinking paradigm than a programming one. Also, it's worth doing away with the client server model too - in Twisted there's just one broker talking in either direction to another.

Take a look here after the above too:

http://twistedmatrix.com/documents/current/core/howto/pb-intro.html

Enjoy :-)