Home > Backend Development > PHP Tutorial > nginx + gevent + django high concurrency configuration django case django website building django build

nginx + gevent + django high concurrency configuration django case django website building django build

WBOY
Release: 2016-07-29 08:53:25
Original
2261 people have browsed it

Startup script

#!/usr/bin/env python
from gevent import monkey; monkey.patch_all()
from gevent import wsgi
from mysite.wsgi import application
HOST = '127.0.0.1'
PORT = 8080
# set spawn=None for memcache
wsgi.WSGIServer((HOST, PORT), application).serve_forever()
Copy after login

Gevent is a greenlet-based Python concurrency framework, with micro-thread greenlet as the core, using the epoll event listening mechanism and many other optimizations to become efficient.

Official website: http://www.djangoproject.com


The above introduces the nginx + gevent + django high-concurrency configuration, including django and event content. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template