Пример #1
0
 def clearqueue():
   while not eventq.empty():
     try:
       EchoConnection.dispatch_all(eventq.get(False))
     except Queue.Empty:
       pass
   tornado.ioloop.IOLoop.instance().add_callback(clearqueue)
Пример #2
0
 def tick():
   EchoConnection.dispatch_all(json.dumps({'time':time.time()}))