コンテンツにスキップ

Web Server Gateway Interface

出典: フリー百科事典『ウィキペディア(Wikipedia)』

Web Server Gateway Interface (WSGI; [1][2]) PythonWebWebWebWSGI

[]


PythonWebPythonWebWeb使WebPythonWebFastCGI, mod_python, CGI, WebAPI使

WSGIWSGIPythonWebWebWSGIWebWSGIWebWSGIWSGI

[]


WSGI  WSGIPythonAPI

Web

(一)

(二)callable __call__ 1callable

(三)callableiterable

(四)

WSGIWSGIWSGIWSGIWSGI""

"":

 URL 





  XSL

WSGI[]


WSGI使WSGIHello World
def application(environ, start_response):
    start_response('200 OK', [('Content-Type', 'text/plain')])
    yield b'Hello World\n'

:

WSGIcallable (__call__)  application  environ CGI start_response callable

start_response 

WSGIiteratablePython使

WSGI Web[]


WSGIWeb:

BlueBream

Bottle

CherryPy

Django

Flask

Google App Engine

Pylons

Pyramid

Tornado (www.tornadoweb.org)

Trac (trac.edgewall.org)

TurboGears

web.py [1]

web2py

Werkzeug

Zope (3)

WSGI[]


WSGIWSGIWSGIHTTPWSGIcallable

WSGIuWSGI, Gunicorn, Apache (mod_wsgi, mod_python), Microsoft IISisapi-wsgi, PyISAPIe, ASP使 

WSGIFastCGISCGICGIPythonwsgiref.handlers.CGIHandler

[]


WSGI

PSGI (Perl Web Server Gateway Interface)

Rack (Ruby Web Server Interface)

SCGI

Ring[] (Clojure)

Clack (Common Lisp)

WAI (Haskell, Web Application Interface)

WSGIPython 3[]


Python 3WSGIHTTPWSGIPython 2Python 3bytesUnicodeWSGIPEP 3333

WSGI Web3 PEP 444 Web3WSGIPython 2.63.1

脚注[編集]

外部リンク[編集]