-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #244 from ploxiln/tornado6
support tornado-6.x, support coroutine message_handler
- Loading branch information
Showing
11 changed files
with
183 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
tornado==3.0.2 | ||
tornado==5.1.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
from __future__ import absolute_import | ||
|
||
import signal | ||
import tornado.ioloop | ||
import logging | ||
|
||
import tornado.ioloop | ||
|
||
from .protocol import ( | ||
Error, | ||
unpack_response, | ||
|
@@ -36,7 +37,7 @@ | |
def _handle_term_signal(sig_num, frame): | ||
logging.getLogger(__name__).info( | ||
'TERM Signal handler called with signal %r', sig_num) | ||
tornado.ioloop.IOLoop.instance().stop() | ||
tornado.ioloop.IOLoop.current().stop() | ||
|
||
|
||
def run(): | ||
|
@@ -45,7 +46,7 @@ def run(): | |
""" | ||
signal.signal(signal.SIGTERM, _handle_term_signal) | ||
signal.signal(signal.SIGINT, _handle_term_signal) | ||
tornado.ioloop.IOLoop.instance().start() | ||
tornado.ioloop.IOLoop.current().start() | ||
|
||
|
||
__author__ = "Matt Reiferson <[email protected]>" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.