T
T
theaidem2013-12-15 23:30:31
Python
theaidem, 2013-12-15 23:30:31

Which framework to choose for a highly loaded Python web application?

Hello, at the design stage, a service that, according to the most daring estimates, should feel free with tens of thousands of visitors at a time, the main thing is the communication of users in private messages (no, this is not another social network), but the principle of instant messaging + ajax notification for incoming will (should be).
At the moment, the priority of using frameworks is as follows:
1. Tornado (for asynchrony).
2. Flask (for lightness).
3. Django (for development speed).
The database plans to use MongoDB (for speed).
JS to manipulate with AngularJS (for fashion/flexibility).
In general, you need advice on what to choose then suddenly your head and booty don’t itch when the service gets life, Tornado or Flask?
Thank you.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
M
maxaon, 2013-12-15
@theaidem

nichol.as/benchmark-of-python-web-servers
Gevent if you need a very fast work. Django if you need to develop quickly.
And think 10 times before using MongoDB.

S
Stanislav Skobelkin, 2013-12-16
@Slko

Flask is more performant in tests. The only thing that confused me a lot was problems with domains if Flask is located behind nginx. I never figured out how to explain to him that he is running at the address where nginx is running. He was convinced that he was running on localhost:81 and all redirects went there.
In this regard, I liked Tornado more, it is more flexible and you can organize any kind of subdomain structure. The problems were only with the lack of human documentation on asynchronous request handlers.
I didn't even look at Django. Does it still not support Python 3.x there? There was no desire to study it, at least not to support outdated technologies. Yes, and some he mainstream-bydlokodersky.
But, probably, Tornado and Flask are more suitable for small projects. Or for large, but with a thorough study of the architecture. This is the wrong choice for a quick riveting of sites in some small company.
Previously, I also used MongoDB, the simplicity of queries and the absence of the need to describe the data structure was very attractive. In addition, the data fit very well into ordinary Python types. Eventually switched to MySQL + SQLAlchemy. The lack of normal transactions in MongoDB caused a lot of inconvenience. The crutches that were offered as replacements were too bulky and difficult to understand.

A
AlexWinner, 2013-12-24
@AlexWinner

Do you want to look at PostgreSQL? All the same, his skype, instagram are used with pleasure. And you will meet fewer pitfalls than in Mongo.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question