Live data from Hacker News

Tornado 2.0 released

groups.google.com

11–20 of 34 posts

Re: Tornado 2.0 released

#11

I know that nobody outside of the Python community cares, but it's disappointing to see that Tornado still doesn't use Twisted for its event handling.

Why would it switch to Twisted if it has always had its own lightweight event loop that's always benchmarked significantly faster? Same goes for fapws3 and gevent.

I can see a lot of reasons to use tornado instead of twisted, but speed is not really one of them. I have not seen a non-trivial benchmark showing one faster than the other (and tornado devs recognize themselves that speed was not that different between the both of them).

Re: Tornado 2.0 released

#12

I know that nobody outside of the Python community cares, but it's disappointing to see that Tornado still doesn't use Twisted for its event handling.

There are some philosophical reasons for not using twisted's io loop (for example, because it uses ctypes to interface with epoll et al, or because of the FactoryFactoryFactory Java envy).

As was mentioned already, competition is good.

Re: Tornado 2.0 released

#13

I know that nobody outside of the Python community cares, but it's disappointing to see that Tornado still doesn't use Twisted for its event handling.

> it's disappointing to see that Tornado still doesn't use Twisted

not using Twisted was the whole point of Tornado, wasn't it? If Tornado used Twisted it wouldn't exist.

Re: Tornado 2.0 released

#14
can not understate just how well written Tornado is. If you are a web app developer, it is well worth reading the source of the project - you will pick up a lot of tips and tricks on developing quick and scalable apps.

outside of the event loop implementation, the framework components are well written - so tornado is worth checking out even if you are running on a more standard type of web server environment or appengine

my own web app stack contains a number of modules either directly from Tornado or inspired by sections of the project

Re: Tornado 2.0 released

#16

I know that nobody outside of the Python community cares, but it's disappointing to see that Tornado still doesn't use Twisted for its event handling.

when Tornado was first released, there was a lot of discussion online on various forums and comment threads about why it wasn't built on top of Twisted, or why it was a complete separate project.

I tend to agree with Brett Taylor in that Twisted was too large a project to suit the goals of Tornado, and that its own divisions within twisted.web were difficult to navigate through

the event handling part of Tornado is less than 100 lines of code and is a lot easier to implement and understand than Twisted, although Twisted also serves a purpose. I like and prefer that Tornado is self-contained and focuses on a single use case (returning JSON in long-polls) and does it well

Re: Tornado 2.0 released

#17

I know that nobody outside of the Python community cares, but it's disappointing to see that Tornado still doesn't use Twisted for its event handling.

I stand on the other end. The reason why I choose tornado for my startup was because it did not use twisted (too early for twisted in my project). Tornado has a great modular structure so you can use each module on its own. The code is lovely to look at too.

Re: Tornado 2.0 released

#18
post #14

can not understate just how well written Tornado is. If you are a web app developer, it is well worth reading the source of the project - you will pick up a lot of tips and tricks on developing quick and scalable apps. outside of the event loop implementation, the framework components are well written - so tornado is worth checking out even if you are running on a more standard type of web server environment or appen…

I found some parts of it to be very poorly written. Like the error handling where it assumes you want to return HTML (remember that Tornado was first written to handle RSS feeds). It also has really poor support for multiprocess mode, where if a child gets killed , the parent does not restart it. Or if the parent is killed, the children may continue running. Also the gzip implementation is broken: if the client mentions gzip even as q=0, Tornado will use it. Just feels like the devs did not not quite pay attention to the details as much as the event loop.

Re: Tornado 2.0 released

#19
Anyone know why they didn't go with Jinja2 for templates? When code is this clean I'm sympathetic towards the "batteries-included" approach, so I'm not criticizing the choice, just wondering if there was a back story, if it got evaluated at all. Same for locale.py vs. PyBabel. The template engine seems far better than Django's at least : )
Post reply on HN