Using Python Tornado to serve Thrift HTTP requests
Python JavaScript
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
gen-py
static
.gitignore
README.md
TJSONProtocol.py
TWebsocketClient.py
client_post.py
client_websocket.py
newservice.thrift
newservicehandler.py
server.py
server_tornado.py

README.md

python_tornado_thrift

Using Python Tornado to serve Thrift HTTP requests.

Project layout:

  1. server.py - regular Thrift HTTP server
  2. server_tornado.py - Tornado powered Thrift HTTP server - accepts both POST and web socket transport protocols
  3. client_post.py - regular Thrift client that uses POST (will work with both servers)
  4. client_websocket.py - Thrift client that uses web sockets for transport
  5. static/index.html - HTML client with Java script Thrift library - accessible through http://localhost:8888/static/index.html when running server_tornado.py