Adds tornado
test server for speed comparison (#13)
This commit is contained in:
parent
452438dc07
commit
cbb1f99ccb
|
@ -8,4 +8,5 @@ tox
|
|||
gunicorn
|
||||
bottle
|
||||
kyoukai
|
||||
falcon
|
||||
falcon
|
||||
tornado
|
19
tests/performance/tornado/simple_server.py
Normal file
19
tests/performance/tornado/simple_server.py
Normal file
|
@ -0,0 +1,19 @@
|
|||
# Run with: python simple_server.py
|
||||
import ujson
|
||||
from tornado import ioloop, web
|
||||
|
||||
|
||||
class MainHandler(web.RequestHandler):
|
||||
def get(self):
|
||||
self.write(ujson.dumps({'test': True}))
|
||||
|
||||
|
||||
app = web.Application([
|
||||
(r'/', MainHandler)
|
||||
], debug=False,
|
||||
compress_response=False,
|
||||
static_hash_cache=True
|
||||
)
|
||||
|
||||
app.listen(8000)
|
||||
ioloop.IOLoop.current().start()
|
Loading…
Reference in New Issue
Block a user