Flask: receiving asynchronous POST requests?

On the python end, I’m envisioning an HTTP end point written in flask to accept data sent from the javascript (asynchronous POST request).

On receiving the POST request, it will write to an sqlite3 database.

The problem I have is that Flask is not asynchronous so how will it handle many POST requests being fired at it and not run into problems?


One option is to use uWSGI in conjunction with the gevent loop in order to avoid blocking.

Check out the docs: http://uwsgi-docs.readthedocs.org/en/latest/Gevent.html

Leave a Reply

Your email address will not be published. Required fields are marked *