changeset 538:a57f1932f05a

gevent
author Matt Johnston <matt@ucc.asn.au>
date Wed, 06 May 2015 19:34:23 +0800
parents 0cc7f2dda0e8
children b78961d2e3a3
files web/templog.py
diffstat 1 files changed, 8 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/web/templog.py	Tue May 05 21:29:19 2015 +0800
+++ b/web/templog.py	Wed May 06 19:34:23 2015 +0800
@@ -75,11 +75,6 @@
         csrf_blob = secure.get_csrf_blob(),
         allowed = allowed)
 
-@route('/set_current.json')
-def set_fresh():
-    response.set_header('Content-Type', 'application/javascript')
-    return log.get_current()
-
 @route('/')
 def top():
 
@@ -140,6 +135,14 @@
 
 secure.setup_csrf()
 
+class TemplogBottle(Bottle):
+    def run(*args, **argm):
+        argm['server'] = 'gevent'
+        super(TemplogBottle, self).run(*args, **argm)
+        print "ran custom bottle"
+
+bottle.app().push(TemplogBottle())
+
 def main():
     #bottle.debug(True)
     #bottle.run(reloader=True)