{
  "version": "https://jsonfeed.org/version/1", 
  "title": "Tornado", 
  "description": "Tornado is an open source version of the scalable, non-blocking web server and tools that power FriendFeed.", 
  "home_page_url": "https://www.v2ex.com/go/tornado", 
  "feed_url": "https://www.v2ex.com/feed/tornado.json", 
  "icon": "https://cdn.v2ex.com/navatar/5272/0e00/361_large.png?m=1579007184", 
  "favicon": "https://cdn.v2ex.com/navatar/5272/0e00/361_normal.png?m=1579007184", 
  "items": [
    {
      "author": {
        "url": "https://www.v2ex.com/member/akura", 
        "name": "akura", 
        "avatar": "https://cdn.v2ex.com/gravatar/27ac91d138177bc90a628c35a8b44cc9?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/619557", 
      "title": "docker \u591a\u8fdb\u7a0b\u90e8\u7f72 tornado", 
      "id": "https://www.v2ex.com/t/619557", 
      "date_published": "2019-11-14T07:30:26+00:00", 
      "content_html": "<ol>\n<li>\u901a\u5e38\u7684\u90e8\u7f72\u65b9\u5f0f\u662f nginx \u8d1f\u8f7d\u5747\u8861\u5230\u591a\u4e2a\u7aef\u53e3\uff0c\u6bcf\u4e2a\u7aef\u53e3\u7ed1\u5b9a\u5f00\u542f\u4e00\u4e2a tornado \u670d\u52a1\uff0c\u901a\u8fc7 supervisor \u53ef\u4ee5\u5f88\u65b9\u4fbf\u76d1\u63a7\u670d\u52a1\u3002</li>\n<li>\u73b0\u5728\u60f3 tornado \u591a\u8fdb\u7a0b\u7528 docker \u90e8\u7f72\uff0c\u5177\u4f53\u7684\u67b6\u6784\u65b9\u6848\u662f\u600e\u4e48\u6837\u7684\uff1f\u662f\u4e00\u4e2a docker \u5bb9\u5668\u4e00\u4e2a\u8fdb\u7a0b\u8fd8\u662f\u4e00\u4e2a docker \u591a\u4e2a\u8fdb\u7a0b\uff1f</li>\n</ol>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/zhze93", 
        "name": "zhze93", 
        "avatar": "https://cdn.v2ex.com/gravatar/15e81bb25e3872f48d6657d5de1d4905?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/558602", 
      "title": "Tornado \u5982\u4f55\u62ff\u5230\u4f20\u8f93\u7684\u6587\u4ef6\u6d41", 
      "id": "https://www.v2ex.com/t/558602", 
      "date_published": "2019-04-25T06:58:13+00:00", 
      "content_html": "<p>\u4e00\u4e2a\u5927\u6587\u4ef6<br>\n\u6211\u5728 client \u901a\u8fc7 requests \u5e93\u6765\u8fdb\u884c\u4f20\u8f93</p>\n<pre><code class=\"language-python3\">with open(path_file, \"rb\") as f:\n    res = requests.post(url, data=f, timeout=600)\n</code></pre>\n<p>\u6211\u5728 server \u7aef\uff0c\u4ece tornado_request \u4e2d\u8be5\u5982\u4f55\u63a5\u6536\u8fd9\u4e2a\u6587\u4ef6\u6d41\u5e76\u4fdd\u5b58\u4e0b\u6765\u5462\u3002<br>\n\u8c22\u8c22\u5404\u4f4d\u7684\u4e0d\u541d\u8d50\u6559\u3002</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/aoscici2000", 
        "name": "aoscici2000", 
        "avatar": "https://cdn.v2ex.com/gravatar/45fecfe863567980c5951ddd8b633a8c?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/527071", 
      "title": "Tornado \u7684\u5f02\u6b65 \u600e\u4e48\u5199\u7684", 
      "id": "https://www.v2ex.com/t/527071", 
      "date_published": "2019-01-14T17:43:42+00:00", 
      "content_html": "<p>\u770b\u5f97\u6559\u7a0b\u4e00\u5934\u96fe\u6c34, \u53ea\u80fd\u7406\u89e3\u90a3\u4e2a\u81ea\u5e26\u7684 http \u8bf7\u6c42, \u770b\u4e86\u5f88\u4e45\u4e5f\u6ca1\u770b\u5230\u6709\u6bd4\u5982\u6570\u636e\u5e93\u67e5\u8be2, \u6587\u4ef6\u5904\u7406\u4ec0\u4e48\u7684\u5176\u4ed6\u4f8b\u5b50, \u540e\u6765\u53bb\u770b\u770b\u5176\u4ed6\u6559\u7a0b, \u5b9e\u73b0\u5012\u7b97\u662f\u52c9\u5f3a\u5b9e\u73b0\u4e86, \u4f46\u611f\u89c9\u4e5f\u592a\u590d\u6742\u4e86\u5427? ?</p>\n<p>\u5c31\u6bd4\u5982\u4f8b\u5b50\u4e2d\u7684\u6211\u5047\u8bbe\u6709\u4e2a\u957f\u8017\u65f6\u7684\u4efb\u52a1, \u600e\u4e48\u5199\u624d\u4f1a\u7b80\u5355\u70b9?</p>\n<pre><code>\nimport tornado.ioloop\nimport tornado.web\nimport time\nimport _thread\n\n\n# \u6a21\u62df\u8017\u65f6\u4efb\u52a1\ndef long_work(arg):\n    time.sleep(5)\n    yield arg * 1024\n\n\ndef mycoroutine(func):\n    def wrapper(self):\n        gen = func(self)\n        work_gen = next(gen)\n        def fun():\n            result = next(work_gen)\n            try:\n            \tgen.send(result)\n            except StopIteration:\n            \tpass\n        _thread.start_new_thread(fun, ())\n    return wrapper\n\n\nclass IndexHandler(tornado.web.RequestHandler):\n    @tornado.web.asynchronous\n    @mycoroutine\n    def get(self):\n        arg = 10    # \u5047\u8bbe\u8bf7\u6c42\u7684\u53c2\u6570\n        result = yield long_work(arg)\n        self.finish(f'&lt;h1&gt;Index {result}&lt;/h1&gt;')\n\n\nclass SyncHandler(tornado.web.RequestHandler):\n    def get(self):\n    \tself.write('&lt;h1&gt;SyncHandler&lt;/h1&gt;')\n\n\ndef make_app():\n    return tornado.web.Application([\n        (r'/', IndexHandler),\n        (r'/sync', SyncHandler)\n    ])\n\n\nif __name__ == '__main__':\n    app = make_app()\n    app.listen(8888)\n    tornado.ioloop.IOLoop.current().start()\n    \n</code></pre>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/aoscici2000", 
        "name": "aoscici2000", 
        "avatar": "https://cdn.v2ex.com/gravatar/45fecfe863567980c5951ddd8b633a8c?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/514006", 
      "title": "tornado \u4e0b ckeditor \u56fe\u7247\u4e0a\u4f20\u95ee\u9898", 
      "id": "https://www.v2ex.com/t/514006", 
      "date_published": "2018-12-03T14:58:02+00:00", 
      "content_html": "<p>\u6309\u7f51\u4e0a\u7684\u65b9\u6cd5\u66f4\u6539\u4e86\u914d\u7f6e\u540e,\u5355\u7eaf\u672c\u5730\u6253\u5f00 html \u6587\u4ef6\u662f\u663e\u793a\u6709\u56fe\u7247\u4e0a\u4f20\u7684\u9009\u9879\u7684, \u4f46\u670d\u52a1\u8dd1\u8d77\u6765\u7684\u65b9\u5f0f\u6253\u5f00\u7684\u8bdd, \u5c31\u6ca1\u6709\u4e86, \u8fd9\u662f\u600e\u4e48\u56de\u4e8b??</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/aoscici2000", 
        "name": "aoscici2000", 
        "avatar": "https://cdn.v2ex.com/gravatar/45fecfe863567980c5951ddd8b633a8c?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/513504", 
      "title": "Tornado \u5f02\u6b65\u600e\u4e48\u5199\u7684?", 
      "id": "https://www.v2ex.com/t/513504", 
      "date_published": "2018-12-02T04:22:59+00:00", 
      "content_html": "<p>\u6bd4\u5982\u8bf4\u8981\u7b49\u67d0\u4e2a\u8017\u65f6\u64cd\u4f5c\u7684\u7ed3\u679c, \u8be5\u600e\u4e48\u5199?</p>\n<p>\u7f51\u4e0a\u770b\u4e86\u534a\u5929\u4f8b\u5b50, \u7167\u7740\u505a\u4e86\u505a, \u8c8c\u4f3c\u884c\u4e0d\u901a</p>\n<p>class AsyncTaskHandler(tornado.web.RequestHandler):</p>\n<pre><code>@tornado.web.asynchronous\n@tornado.gen.coroutine\ndef get(self, *args, **kwargs):\n    resp = yield tornado.gen.Task(self.do_something)\n    self.finish(resp)\n\n@tornado.gen.coroutine\ndef do_something(self, *args, **kwargs):\n    time.sleep(10)\n    return {'message': 'OKOK'}\n</code></pre>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/kidlfy", 
        "name": "kidlfy", 
        "avatar": "https://cdn.v2ex.com/avatar/3e87/2256/347016_large.png?m=1536907363"
      }, 
      "url": "https://www.v2ex.com/t/512202", 
      "title": "tornado \u600e\u4e48\u80fd\u786e\u4fdd\u7aef\u53e3\u6302\u4e86 \u670d\u52a1\u4e5f\u4e0d\u4f1a\u505c\u6b62\uff1f", 
      "id": "https://www.v2ex.com/t/512202", 
      "date_published": "2018-11-28T02:00:59+00:00", 
      "content_html": "<p>\u5c0f\u767d python\ntornado \u4e5f\u4e0d\u719f \u521a\u8bd5\u7740\u7528\n\u9700\u8981\u914d\u7f6e\u4e24\u4e2a\u7aef\u53e3\u6765\u4fdd\u8bc1 \u4e00\u4e2a\u7aef\u53e3\u6302\u4e86\u53e6\u4e00\u4e2a\u4f1a\u8d77\u6765 \u670d\u52a1\u4e0d\u4f1a\u7ec8\u6b62\n\u901a\u8fc7 nginx \u8981\u600e\u4e48\u914d\u7f6e\uff1f\n\u8981\u54ed\u4e86\n\u4e0d\u4f1a\u505a\n\u5f88\u5c34\u5c2c</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/everlasting_188", 
        "name": "everlasting_188", 
        "avatar": "https://cdn.v2ex.com/gravatar/810276494571f641863966d535c74c9a?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/467856", 
      "date_modified": "2018-07-03T14:46:57+00:00", 
      "content_html": "", 
      "date_published": "2018-07-03T09:51:59+00:00", 
      "title": "Tornado \u8def\u7531\u6709\u4ec0\u4e48\u597d\u65b9\u6cd5\uff0c\u4e00\u4e2a\u4e00\u4e2a\u5199\u592a\u9ebb\u70e6\u4e86\uff0c\u6709\u6ca1\u6709\u6839\u636e url \u548c\u6ce8\u89e3\u5339\u914d\u7684\u65b9\u6cd5\u5462", 
      "id": "https://www.v2ex.com/t/467856"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/mywaiting", 
        "name": "mywaiting", 
        "avatar": "https://cdn.v2ex.com/avatar/4f87/658e/1340_large.png?m=1733248338"
      }, 
      "url": "https://www.v2ex.com/t/350765", 
      "date_modified": "2017-03-27T16:35:11+00:00", 
      "content_html": "\u8bb0\u5f97\u5148\u524d\u6709\u4e2a issue \u63d0\u53ca\u5230 routing \u7684\u95ee\u9898\u7684\uff0c\u6df1\u591c\u7ffb\u4e00\u4e0b Tornado \u7684\u4ee3\u7801\uff0c\u521a\u521a\u597d\u9047\u4e0a update \u5230 v4.5\r<br />\r<br />\u591a\u4e86\u8fd9\u4e48\u4e00\u4e2a routing \u7684\u5b9e\u73b0\uff0c\u7ec8\u4e8e\u6709\u4e86\u4e00\u4e2a\u5b98\u65b9\u70b9\u7684\u7a0d\u5fae\u597d\u770b\u4f18\u96c5\u70b9\u7684\u65b9\u5f0f\u53bb\u7ec4\u7ec7 Tornado \u7684 Application \u548c Handler \u4e86\r<br />\r<br />\u76f4\u63a5\u770b\u4ee3\u7801\u5427  <a target=\"_blank\" href=\"https://github.com/tornadoweb/tornado/blob/master/tornado/routing.py\" rel=\"nofollow\">https://github.com/tornadoweb/tornado/blob/master/tornado/routing.py</a> \u5b98\u65b9\u7684\u6587\u6863\u90fd\u8fd8\u6ca1\u6709\u66f4\u65b0\r<br />\r<br />Tornado \u7684\u4ee3\u7801\u5199\u5f97\u633a\u4f18\u96c5\u7684\uff0c\u5f88\u9002\u5408\u56f4\u89c2", 
      "date_published": "2017-03-27T16:33:42+00:00", 
      "title": "Tornado V4.5 release", 
      "id": "https://www.v2ex.com/t/350765"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/lecher", 
        "name": "lecher", 
        "avatar": "https://cdn.v2ex.com/gravatar/51e6526f4f1ab6541a075b0a2d3decc4?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/345167", 
      "title": "pypy \u62ff\u5230\u8d5e\u52a9\u4e4b\u540e\u51fa\u4e86\u652f\u6301 Python3.5 \u7684\u7248\u672c", 
      "id": "https://www.v2ex.com/t/345167", 
      "date_published": "2017-03-05T15:26:08+00:00", 
      "content_html": "\u770b\u535a\u5ba2\u4e0a\u9762\u7684\u8bc4\u6d4b\uff0c\u6027\u80fd\u8868\u73b0\u5f88\u4e0d\u9519\u3002\r<br /><a target=\"_blank\" href=\"https://morepypy.blogspot.jp/2017/03/async-http-benchmarks-on-pypy3.html?m=1\" rel=\"nofollow\">https://morepypy.blogspot.jp/2017/03/async-http-benchmarks-on-pypy3.html?m=1</a>\r<br />\r<br />UVloop \u65b0\u7248\u672c\u4e5f\u5f00\u653e\u4e86\u5bf9 tornado \u7684\u652f\u6301\u3002\r<br /><a target=\"_blank\" href=\"https://github.com/Magicstack/uvloop/issues/35\" rel=\"nofollow\">https://github.com/Magicstack/uvloop/issues/35</a>\r<br />\r<br />\u770b\u76ee\u524d\u7f51\u7edc\u4e0a\u9762\u7684\u8bc4\u6d4b sanic+uvloop \u8bc4\u6d4b\u6570\u636e\u9065\u9065\u9886\u5148\u3002\r<br />\u5982\u679c pypy \u652f\u6301 Python3.5 \u4e4b\u540e\uff0c pypy+uvloop+tornado \u53ef\u4ee5\u8dd1\u51fa\u4ec0\u4e48\u6837\u7684\u6570\u636e\uff1f"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/sylvos", 
        "name": "sylvos", 
        "avatar": "https://cdn.v2ex.com/gravatar/5cf33c002b707fe9225a380266a236be?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/332360", 
      "title": "\u8bf7\u6559 tornado \u6587\u4ef6\u4e0a\u4f20\u95ee\u9898", 
      "id": "https://www.v2ex.com/t/332360", 
      "date_published": "2017-01-05T03:59:03+00:00", 
      "content_html": "\u7528\u4e0b\u9762\u7684\u4ee3\u7801\u505a\u6587\u4ef6\u4e0a\u4f20\uff0c\u5728\u81ea\u5df1\u7535\u8111\u6d4b\u8bd5\u80fd\u591f\u6210\u529f\u4e0a\u4f20\uff0c\u5230\u5c40\u57df\u7f51\u5176\u4ed6\u7535\u8111\u6d4b\u8bd5\uff0c\u663e\u793a finished!\u4e86\uff0c\u4f46\u662f\u6ca1\u770b\u5230\u6587\u4ef6\uff0c\u8bf7\u95ee\u524d\u8f88\uff0c\u662f\u4ec0\u4e48\u539f\u56e0\u5462\uff1f\u8be5\u4ee3\u7801\u8fd0\u884c\u5728 xp \u7cfb\u7edf\u4e0a\uff0c\u4e0a\u4f20\u6587\u4ef6\u5939\u5df2\u8bbe\u7f6e\u6700\u9ad8\u6743\u9650\u3002\r<br />import tornado.ioloop\r<br />import tornado.web\r<br />import shutil\r<br />import os\r<br />\r<br />class UploadFileHandler(tornado.web.RequestHandler):\r<br />    def get(self):\r<br />        self.write('''\r<br />&lt;html&gt;\r<br />  &lt;head&gt;&lt;title&gt;Upload File&lt;/title&gt;&lt;/head&gt;\r<br />  &lt;body&gt;\r<br />    &lt;form action='file' enctype=&quot;multipart/form-data&quot; method='post'&gt;\r<br />    &lt;input type='file' name='file'/&gt;&lt;br/&gt;\r<br />    &lt;input type='submit' value='submit'/&gt;\r<br />    &lt;/form&gt;\r<br />  &lt;/body&gt;\r<br />&lt;/html&gt;\r<br />''')\r<br />\r<br />    def post(self):\r<br />        upload_path=os.path.join(os.path.dirname(__file__),'files')  #\u6587\u4ef6\u7684\u6682\u5b58\u8def\u5f84\r<br />        file_metas=self.request.files['file']    #\u63d0\u53d6\u8868\u5355\u4e2d\u2018 name \u2019\u4e3a\u2018 file \u2019\u7684\u6587\u4ef6\u5143\u6570\u636e\r<br />        for meta in file_metas:\r<br />            filename=meta['filename']\r<br />            filepath=os.path.join(upload_path,filename)\r<br />            with open(filepath,'wb') as up:      #\u6709\u4e9b\u6587\u4ef6\u9700\u8981\u5df2\u4e8c\u8fdb\u5236\u7684\u5f62\u5f0f\u5b58\u50a8\uff0c\u5b9e\u9645\u4e2d\u53ef\u4ee5\u66f4\u6539\r<br />                up.write(meta['body'])\r<br />            self.write('finished!')\r<br />\r<br />app=tornado.web.Application([\r<br />    (r'/file',UploadFileHandler),\r<br />])\r<br />\r<br />if __name__ == '__main__':\r<br />    app.listen(3000)\r<br />    tornado.ioloop.IOLoop.instance().start()"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/feelapi", 
        "name": "feelapi", 
        "avatar": "https://cdn.v2ex.com/avatar/8c06/9f21/36491_large.png?m=1425350253"
      }, 
      "url": "https://www.v2ex.com/t/327437", 
      "title": "tornado \u505a\u540e\u53f0\u670d\u52a1\uff0c\u5982\u679c\u524d\u7aef\u6ca1\u6709\u7528 cookie.", 
      "id": "https://www.v2ex.com/t/327437", 
      "date_published": "2016-12-13T13:48:27+00:00", 
      "content_html": "<p>\u662f\u4e0d\u662f\u5c31\u4e0d\u7528\u589e\u52a0 XSRF \u7684\u652f\u6301\u4e86\uff0c\u6bd5\u7adf\u8fd9\u4e2a\u8fd8\u662f\u7528\u6765\u5904\u7406 cookie \u7684\u3002</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/burnex", 
        "name": "burnex", 
        "avatar": "https://cdn.v2ex.com/avatar/dbe3/bcfb/37711_large.png?m=1393683848"
      }, 
      "url": "https://www.v2ex.com/t/321411", 
      "title": "tornado \u4f18\u79c0\u9879\u76ee\u63a8\u8350", 
      "id": "https://www.v2ex.com/t/321411", 
      "date_published": "2016-11-18T02:58:16+00:00", 
      "content_html": "<p>\u6253\u7b97\u597d\u597d\u5b66\u4e60\u4e0b tornado \uff0c\u8bf7\u5927\u5bb6\u63a8\u8350\u4e00\u4e9b\u597d\u7684 tornado \u9879\u76ee\uff0c\u8c22\u8c22</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/tomhe", 
        "name": "tomhe", 
        "avatar": "https://cdn.v2ex.com/gravatar/cc514dbe148cdb0b2fe1e7c9554b0893?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/300584", 
      "title": "\u95ee\u4e00\u4e2a tornado \u89e3\u51b3\u963b\u585e\u7684\u65b9\u6848\u95ee\u9898\uff1f", 
      "id": "https://www.v2ex.com/t/300584", 
      "date_published": "2016-08-20T02:25:35+00:00", 
      "content_html": "\u73b0\u5728\u7684\u9700\u6c42\u662f\uff1a\r<br />\u624b\u673a app \u4e0a\u4f20\u56fe\u7247-&gt;tornado \u8c03\u7528 c++\u7b97\u6cd5\u5e93\u5904\u7406-&gt;\u5411\u624b\u673a\u8fd4\u56de\u7ed3\u679c\u3002\r<br />\u76ee\u524d\u9047\u5230\u7684\u95ee\u9898\u662f c++\u7b97\u6cd5\u5e93\u9700\u8981\u8017\u65f6 1 \u79d2\u5de6\u53f3\uff0c\u8fd9\u6837\u4f1a\u628a\u6574\u4e2a tornado \u963b\u585e\u4f4f\u5427\uff1f\u6709\u4ec0\u4e48\u597d\u7684\u5f02\u6b65\u89e3\u51b3\u65b9\u6cd5\u6216\u601d\u8def\u5417\uff1f\r<br />\u8bf7\u95ee\u6211\u8fd9\u4e2a\u9700\u6c42\u53ef\u4ee5\u7528\u534f\u7a0b\u7684\u65b9\u5f0f\u89e3\u51b3\u5417\uff1f\u8fd8\u662f\u7528\u591a\u8fdb\u7a0b\u7684\u65b9\u5f0f\u89e3\u51b3?"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/whoareyou", 
        "name": "whoareyou", 
        "avatar": "https://cdn.v2ex.com/avatar/cee8/c44e/182956_large.png?m=1469075398"
      }, 
      "url": "https://www.v2ex.com/t/297680", 
      "title": "tornaqiniu(\u57fa\u4e8e tornado \u7684\u5f02\u6b65\u4e03\u725b sdk)", 
      "id": "https://www.v2ex.com/t/297680", 
      "date_published": "2016-08-07T05:41:53+00:00", 
      "content_html": "<p>\u6700\u8fd1\u5728\u7528 Python \u5f00\u53d1\u4e00\u4e2a\u81ea\u5df1\u7684\u7f51\u7ad9\uff0c\u8981\u7528\u5230\u4e03\u725b\u505a\u4e3a\u7f51\u7ad9\u7684 storage \uff0c\u4f46\u662f\u4e03\u725b\u5b98\u65b9 sdk \u4e0d\u652f\u6301\u5f02\u6b65\uff0c\u6240\u4ee5\u6253\u7b97\u81ea\u5df1\u5199\u4e00\u4e2a\u5f02\u6b65\u7684 sdk \u3002\u5199\u51fa\u6765\u4e4b\u540e\u81ea\u5df1\u7528\u7740\u8fd8\u53ef\u4ee5\uff0c\u6240\u4ee5\u60f3\u7ed9\u5927\u5bb6\u5206\u4eab\u4e00\u4e0b\uff0c\u4e0d\u559c\u52ff\u55b7\u3002</p>\n<p>python version : &gt;=3.4</p>\n<p>github: <a href=\"https://github.com/free-free/tornaqiniu\" rel=\"nofollow\">https://github.com/free-free/tornaqiniu</a></p>\n<p>doc: <a href=\"https://github.com/free-free/tornaqiniu\" rel=\"nofollow\">https://github.com/free-free/tornaqiniu</a></p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/aiqier", 
        "name": "aiqier", 
        "avatar": "https://cdn.v2ex.com/gravatar/7722f001ef46dc94410465ebfdf2ac3b?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/289477", 
      "date_modified": "2016-06-30T14:47:11+00:00", 
      "content_html": "<p>tornado \u53ef\u4ee5\u4f7f\u7528\u5982\u4e0b\u65b9\u5f0f\u5e76\u884c\u5f02\u6b65\u8bf7\u6c42\u3002</p>\n<pre><code>@gen.coroutine\ndef get(self):\n    http_client = AsyncHTTPClient()\n    response1, response2 = yield [http_client.fetch(url1),\n                                  http_client.fetch(url2)]\n</code></pre>\n<p>\u8fd9\u4e2a\u65f6\u5019\uff0c 1,2 \u662f\u540c\u65f6\u53d1\u9001\u51fa\u53bb\u7684\uff0c\u4e5f\u5c31\u662f\u8bf4\u4f7f\u7528\u8fd9\u79cd\u65b9\u5f0f\uff0c\u53ef\u4ee5\u8ba9 n \u4e2a\u8bf7\u6c42\uff0c\u540c\u65f6\u53d1\u51fa\u53bb\uff0c\u7b49\u4ed6\u4eec\u90fd\u8fd4\u56de\u4e86\u518d\u7edf\u4e00\u8fd4\u56de\u3002</p>\n<p>\u90a3\u4e48\u6211\u8981\u5982\u4f55\u4fdd\u8bc1\uff0c\u5176\u4e2d\u4e00\u4e2a\u8bf7\u6c42\u574f\u4e86\uff0c\u5176\u4f59\u7684\u7ed3\u679c\u4f9d\u65e7\u53ef\u7528\uff1f</p>\n", 
      "date_published": "2016-06-30T14:46:47+00:00", 
      "title": "tornado \u5e76\u884c\u5f02\u6b65\uff0c\u5982\u4f55\u4fdd\u8bc1\u5728\u53ea\u6709\u90e8\u5206\u8bf7\u6c42\u6210\u529f\u540e\uff0c\u7ed3\u679c\u4f9d\u65e7\u53ef\u7528\u3002", 
      "id": "https://www.v2ex.com/t/289477"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/qiu0130", 
        "name": "qiu0130", 
        "avatar": "https://cdn.v2ex.com/avatar/1e44/2104/139692_large.png?m=1443080447"
      }, 
      "url": "https://www.v2ex.com/t/289074", 
      "title": "nginx \u53cd\u5411\u4ee3\u7406 tornado,\u5982\u4f55 location \u9996\u9875\uff55 rl?", 
      "id": "https://www.v2ex.com/t/289074", 
      "date_published": "2016-06-29T03:54:36+00:00", 
      "content_html": "<p><code>nginx</code>\u53cd\u5411\u4ee3\u7406<code>tornado</code>\u5b9e\u4f8b\uff0c\u600e\u4e48\u91cd\u5b9a\u5411\u5230\u9996\u9875<code>url</code></p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/mgna17", 
        "name": "mgna17", 
        "avatar": "https://cdn.v2ex.com/avatar/cdc8/3877/144263_large.png?m=1445743013"
      }, 
      "url": "https://www.v2ex.com/t/283654", 
      "date_modified": "2016-06-05T09:26:59+00:00", 
      "content_html": "<p>\u521a\u5f00\u59cb\u5b66 tornado \uff0c\u5b83\u7684\u5f02\u5e38\u5904\u7406\u673a\u5236\u6709\u70b9\u5f04\u4e0d\u660e\u767d\u3002</p>\n<p>\u5199\u4e86\u4e00\u4e2a\u6d4b\u8bd5\u7528\u7684\u5c0f\u811a\u672c\uff0c\u671f\u671b\u9047\u5230 404 \u7684\u65f6\u5019\u80fd\u591f\u89e6\u53d1\u6211\u81ea\u5df1\u58f0\u660e\u7684 write_error \u51fd\u6570\uff0c\u7136\u800c write_error \u5e76\u6ca1\u6709\u751f\u6548\uff0c\u8f93\u51fa\u7684\u662f tornado \u9ed8\u8ba4\u7684 404 \u9875\u9762\u3002</p>\n<p>\u4ee3\u7801\u5982\u4e0b\uff1a</p>\n<pre><code>#!/bin/env python3.5\n#coding:utf-8\nimport os\n\nimport tornado.httpserver\nimport tornado.ioloop\nimport tornado.options\nimport tornado.web\n\nfrom tornado.options import define, options\n\ndefine(\"port\", default=8000, help=\"\u7aef\u53e3\", type=int)\n\nclass BaseHandler(tornado.web.RequestHandler):\n    def write_error(self, stat, **kw):\n        self.write('Func write_error !')\n\n\nclass IndexHandler(BaseHandler):\n    def get(self):\n        self.write('hello')\n\nhandlers = [ \n    (r'/index', IndexHandler),\n    ]   \n\nsettings = { \n        'template_path': os.path.join(os.path.dirname(__file__), \"templates\"),\n        'static_path': os.path.join(os.path.dirname(__file__), 'static'),\n        }\n\nif __name__ == '__main__':\n        tornado.options.parse_command_line()\n        app = tornado.web.Application(handlers=handlers, **settings)\n        http_server = tornado.httpserver.HTTPServer(app)\n        http_server.listen(options.port)\n        print(options.port)\n        tornado.ioloop.IOLoop.instance().start()\n</code></pre>\n<p>\u7136\u540e\u53bb google \u4e86\u4e00\u4e0b\uff0c\u628a BaseHandler \u6210\u4e86\u8fd9\u6837\uff0c\u4f46\u662f 404 \u7684\u65f6\u5019\u8fd8\u662f\u8fd4\u56de\u4e86\u9ed8\u8ba4\u7684 404 \u9875\u9762\uff1a</p>\n<pre><code>class BaseHandler(tornado.web.RequestHandler):\n    def _handle_request_exception(self, e):\n        self.write_error(404)\n\n    def send_error(self, stat, **kw):\n        self.write_error(404)\n\n    def write_error(self, stat, **kw):\n        self.write('Func write_error !')\n</code></pre>\n", 
      "date_published": "2016-06-05T09:07:42+00:00", 
      "title": "\u95ee\u4e00\u4e2a\u5173\u4e8e tornado \u5f02\u5e38\u5904\u7406\u7684\u65b0\u624b\u95ee\u9898", 
      "id": "https://www.v2ex.com/t/283654"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/triThirty", 
        "name": "triThirty", 
        "avatar": "https://cdn.v2ex.com/avatar/464b/8ffa/122253_large.png?m=1441520884"
      }, 
      "url": "https://www.v2ex.com/t/269198", 
      "title": "tornado \u7684 coroutine \u80fd\u548c\u81ea\u5b9a\u4e49\u7684\u88c5\u9970\u5668\u4e00\u8d77\u4f7f\u7528\u5417\uff1f\uff1f", 
      "id": "https://www.v2ex.com/t/269198", 
      "date_published": "2016-04-07T03:45:17+00:00", 
      "content_html": "<p>\u8bd5\u4e86\u4e0b\u4f7f\u7528 tornado \u7684 coroutine \u548c\u81ea\u5df2\u5b9a\u4e49\u7684\u4e00\u4e2a decorator \u4e00\u8d77\u4f7f\u7528\uff0c\u4f46\u53d1\u73b0\u4e0d\u4f1a\u5728 yield \u51fa\u6302\u8d77\uff0c\u800c\u662f\u5411\u4e0a\u8fd4\u56de\u3002\n\u5c31\u662f\u8bf4\uff0c\u5982\u679c\u6709\u591a\u5c42\u5d4c\u5957\u7684\u8bdd\uff0c\u5728\u8fd0\u884c\u5230\u6700\u5e95\u5c42\u7684 yield \u5904\u4e4b\u540e\uff0c\u7a0b\u5e8f\u4e0d\u4f1a\u8fd0\u884c yield \u4e4b\u540e\u7684\u4ee3\u7801\uff0c\u800c\u662f\u5411\u4e0a\u8fd4\u56de\u4e00\u4e2a\u7a7a\u7684 future \uff0c\u800c\u4e14\u4e0a\u5c42\u4ee3\u7801\u4e5f\u4e0d\u4f1a\u6267\u884c yield \u4e4b\u540e\u7684\u4ee3\u7801\u800c\u662f\u7ee7\u7eed\u5411\u4e0a\u8fd4\u56de\u3002\n\u4e0d\u77e5\u9053\u6709\u6ca1\u6709\u5927\u795e\u80fd\u7ed9\u51fa\u4e00\u4e2a\u4f8b\u5b50\uff0c\u5c06 coroutine \u548c\u81ea\u5b9a\u4e49\u7684\u88c5\u9970\u5668\u4e00\u8d77\u4f7f\u7528\u7684\u4f8b\u5b50\uff0c\u6216\u8005\u8bf4\u80fd\u6307\u51fa\u600e\u4e48\u4f7f\u7528\u3002\u8c22\u8c22</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/bluesky139", 
        "name": "bluesky139", 
        "avatar": "https://cdn.v2ex.com/avatar/119f/6887/72959_large.png?m=1432863459"
      }, 
      "url": "https://www.v2ex.com/t/250767", 
      "title": "Tornado \u5e76\u53d1\u6570\u5f88\u4f4e\uff0c\u6b63\u5e38\u4e48\uff1f", 
      "id": "https://www.v2ex.com/t/250767", 
      "date_published": "2016-01-14T09:47:48+00:00", 
      "content_html": "\u5728 localhost \u4e0b\u6d4b\u8bd5\uff0c\u50cf demo \u4e00\u6837\uff0c get \u6216 post \u91cc\u9762\u6ca1\u6709\u4efb\u4f55\u591a\u4f59\u7684\u8017\u65f6\u4ee3\u7801\uff0c\u76f4\u63a5\u8fd4\u56de\u3002\r<br />\u5f97\u5230\u7684\u7ed3\u679c\u662f\u6bcf\u79d2 200 \u591a\u7684\u5e76\u53d1\u6570\uff0c\u8fd9\u6b63\u5e38\u4e48\uff1f\r<br />\r<br />\u76ee\u524d\u7cfb\u7edf\u662f win7 \uff0c CPU \u662f E3 1231 \uff0c\r<br />\u4ece\u4efb\u52a1\u7ba1\u7406\u5668\u6765\u770b\uff0c\u4f3c\u4e4e\u662f\u5355\u7ebf\u7a0b\u8dd1\u6ee1\u4e86\uff08\u56e0\u4e3a\u8fdb\u7a0b\u7684 CPU \u5360\u7528\u7387\u4e3a 13 \uff09\u3002\r<br />\u5404\u4f4d\u7528 tornado \u7684\u670b\u53cb\u4e5f\u662f\u540c\u6837\u7684\u7ed3\u679c\u4e48? \u8fd8\u662f\u8bf4\u54ea\u91cc\u6709\u5751\uff1f"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/kidlj", 
        "name": "kidlj", 
        "avatar": "https://cdn.v2ex.com/avatar/7d66/788d/48786_large.png?m=1735461327"
      }, 
      "url": "https://www.v2ex.com/t/248581", 
      "title": "\u9605\u8bfb Tornado \u6e90\u7801\u8fc7\u7a0b\u4e2d\u7684\u4e00\u4e2a\u7591\u60d1\uff0c\u6c42\u89e3\u7b54", 
      "id": "https://www.v2ex.com/t/248581", 
      "date_published": "2016-01-05T11:50:34+00:00", 
      "content_html": "<p>\u4e0b\u9762\u662f <code>tornado.httpclient.AsyncHTTPClient</code>\u7c7b\u7684 <code>fetch()</code>\u65b9\u6cd5\u7684\u6e90\u4ee3\u7801\u3002\u6211\u6ca1\u6709\u5728\u91cc\u9762\u627e\u5230\u4efb\u4f55&quot;fetch&quot;\u7684\u52a8\u4f5c\uff0c\u5b83\u662f\u600e\u4e48\u5b9e\u73b0 \u201c Executes a request, asynchronously returning an <code>HTTPResponse</code>\u201d\u7684\uff1f</p>\n\n<p>\u5b8c\u6574\u4ee3\u7801\u5728\uff1a <a target=\"_blank\" rel=\"nofollow\" href=\"https://github.com/tornadoweb/tornado/blob/master/tornado/httpclient.py\">https://github.com/tornadoweb/tornado/blob/master/tornado/httpclient.py</a></p>\n<div class=\"highlight\"><pre><span class=\"k\">def</span> <span class=\"nf\">fetch</span><span class=\"p\">(</span><span class=\"bp\">self</span><span class=\"p\">,</span> <span class=\"n\">request</span><span class=\"p\">,</span> <span class=\"n\">callback</span><span class=\"o\">=</span><span class=\"bp\">None</span><span class=\"p\">,</span> <span class=\"n\">raise_error</span><span class=\"o\">=</span><span class=\"bp\">True</span><span class=\"p\">,</span> <span class=\"o\">**</span><span class=\"n\">kwargs</span><span class=\"p\">):</span>\n        <span class=\"sd\">&quot;&quot;&quot;Executes a request, asynchronously returning an `HTTPResponse`.</span>\n<span class=\"sd\">        The request may be either a string URL or an `HTTPRequest` object.</span>\n<span class=\"sd\">        If it is a string, we construct an `HTTPRequest` using any additional</span>\n<span class=\"sd\">        kwargs: ``HTTPRequest(request, **kwargs)``</span>\n<span class=\"sd\">        This method returns a `.Future` whose result is an</span>\n<span class=\"sd\">        `HTTPResponse`. By default, the ``Future`` will raise an</span>\n<span class=\"sd\">        `HTTPError` if the request returned a non-200 response code</span>\n<span class=\"sd\">        (other errors may also be raised if the server could not be</span>\n<span class=\"sd\">        contacted). Instead, if ``raise_error`` is set to False, the</span>\n<span class=\"sd\">        response will always be returned regardless of the response</span>\n<span class=\"sd\">        code.</span>\n<span class=\"sd\">        If a ``callback`` is given, it will be invoked with the `HTTPResponse`.</span>\n<span class=\"sd\">        In the callback interface, `HTTPError` is not automatically raised.</span>\n<span class=\"sd\">        Instead, you must check the response&#39;s ``error`` attribute or</span>\n<span class=\"sd\">        call its `~HTTPResponse.rethrow` method.</span>\n<span class=\"sd\">        &quot;&quot;&quot;</span>\n        <span class=\"k\">if</span> <span class=\"bp\">self</span><span class=\"o\">.</span><span class=\"n\">_closed</span><span class=\"p\">:</span>\n            <span class=\"k\">raise</span> <span class=\"ne\">RuntimeError</span><span class=\"p\">(</span><span class=\"s\">&quot;fetch() called on closed AsyncHTTPClient&quot;</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span> <span class=\"ow\">not</span> <span class=\"nb\">isinstance</span><span class=\"p\">(</span><span class=\"n\">request</span><span class=\"p\">,</span> <span class=\"n\">HTTPRequest</span><span class=\"p\">):</span>\n            <span class=\"n\">request</span> <span class=\"o\">=</span> <span class=\"n\">HTTPRequest</span><span class=\"p\">(</span><span class=\"n\">url</span><span class=\"o\">=</span><span class=\"n\">request</span><span class=\"p\">,</span> <span class=\"o\">**</span><span class=\"n\">kwargs</span><span class=\"p\">)</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"k\">if</span> <span class=\"n\">kwargs</span><span class=\"p\">:</span>\n                <span class=\"k\">raise</span> <span class=\"ne\">ValueError</span><span class=\"p\">(</span><span class=\"s\">&quot;kwargs can&#39;t be used if request is an HTTPRequest object&quot;</span><span class=\"p\">)</span>\n        <span class=\"c\"># We may modify this (to add Host, Accept-Encoding, etc),</span>\n        <span class=\"c\"># so make sure we don&#39;t modify the caller&#39;s object.  This is also</span>\n        <span class=\"c\"># where normal dicts get converted to HTTPHeaders objects.</span>\n        <span class=\"n\">request</span><span class=\"o\">.</span><span class=\"n\">headers</span> <span class=\"o\">=</span> <span class=\"n\">httputil</span><span class=\"o\">.</span><span class=\"n\">HTTPHeaders</span><span class=\"p\">(</span><span class=\"n\">request</span><span class=\"o\">.</span><span class=\"n\">headers</span><span class=\"p\">)</span>\n        <span class=\"n\">request</span> <span class=\"o\">=</span> <span class=\"n\">_RequestProxy</span><span class=\"p\">(</span><span class=\"n\">request</span><span class=\"p\">,</span> <span class=\"bp\">self</span><span class=\"o\">.</span><span class=\"n\">defaults</span><span class=\"p\">)</span>\n        <span class=\"n\">future</span> <span class=\"o\">=</span> <span class=\"n\">TracebackFuture</span><span class=\"p\">()</span>\n        <span class=\"k\">if</span> <span class=\"n\">callback</span> <span class=\"ow\">is</span> <span class=\"ow\">not</span> <span class=\"bp\">None</span><span class=\"p\">:</span>\n            <span class=\"n\">callback</span> <span class=\"o\">=</span> <span class=\"n\">stack_context</span><span class=\"o\">.</span><span class=\"n\">wrap</span><span class=\"p\">(</span><span class=\"n\">callback</span><span class=\"p\">)</span>\n\n            <span class=\"k\">def</span> <span class=\"nf\">handle_future</span><span class=\"p\">(</span><span class=\"n\">future</span><span class=\"p\">):</span>\n                <span class=\"n\">exc</span> <span class=\"o\">=</span> <span class=\"n\">future</span><span class=\"o\">.</span><span class=\"n\">exception</span><span class=\"p\">()</span>\n                <span class=\"k\">if</span> <span class=\"nb\">isinstance</span><span class=\"p\">(</span><span class=\"n\">exc</span><span class=\"p\">,</span> <span class=\"n\">HTTPError</span><span class=\"p\">)</span> <span class=\"ow\">and</span> <span class=\"n\">exc</span><span class=\"o\">.</span><span class=\"n\">response</span> <span class=\"ow\">is</span> <span class=\"ow\">not</span> <span class=\"bp\">None</span><span class=\"p\">:</span>\n                    <span class=\"n\">response</span> <span class=\"o\">=</span> <span class=\"n\">exc</span><span class=\"o\">.</span><span class=\"n\">response</span>\n                <span class=\"k\">elif</span> <span class=\"n\">exc</span> <span class=\"ow\">is</span> <span class=\"ow\">not</span> <span class=\"bp\">None</span><span class=\"p\">:</span>\n                    <span class=\"n\">response</span> <span class=\"o\">=</span> <span class=\"n\">HTTPResponse</span><span class=\"p\">(</span>\n                        <span class=\"n\">request</span><span class=\"p\">,</span> <span class=\"mi\">599</span><span class=\"p\">,</span> <span class=\"n\">error</span><span class=\"o\">=</span><span class=\"n\">exc</span><span class=\"p\">,</span>\n                        <span class=\"n\">request_time</span><span class=\"o\">=</span><span class=\"n\">time</span><span class=\"o\">.</span><span class=\"n\">time</span><span class=\"p\">()</span> <span class=\"o\">-</span> <span class=\"n\">request</span><span class=\"o\">.</span><span class=\"n\">start_time</span><span class=\"p\">)</span>\n                <span class=\"k\">else</span><span class=\"p\">:</span>\n                    <span class=\"n\">response</span> <span class=\"o\">=</span> <span class=\"n\">future</span><span class=\"o\">.</span><span class=\"n\">result</span><span class=\"p\">()</span>\n                <span class=\"bp\">self</span><span class=\"o\">.</span><span class=\"n\">io_loop</span><span class=\"o\">.</span><span class=\"n\">add_callback</span><span class=\"p\">(</span><span class=\"n\">callback</span><span class=\"p\">,</span> <span class=\"n\">response</span><span class=\"p\">)</span>\n            <span class=\"n\">future</span><span class=\"o\">.</span><span class=\"n\">add_done_callback</span><span class=\"p\">(</span><span class=\"n\">handle_future</span><span class=\"p\">)</span>\n\n        <span class=\"k\">def</span> <span class=\"nf\">handle_response</span><span class=\"p\">(</span><span class=\"n\">response</span><span class=\"p\">):</span>\n            <span class=\"k\">if</span> <span class=\"n\">raise_error</span> <span class=\"ow\">and</span> <span class=\"n\">response</span><span class=\"o\">.</span><span class=\"n\">error</span><span class=\"p\">:</span>\n                <span class=\"n\">future</span><span class=\"o\">.</span><span class=\"n\">set_exception</span><span class=\"p\">(</span><span class=\"n\">response</span><span class=\"o\">.</span><span class=\"n\">error</span><span class=\"p\">)</span>\n            <span class=\"k\">else</span><span class=\"p\">:</span>\n                <span class=\"n\">future</span><span class=\"o\">.</span><span class=\"n\">set_result</span><span class=\"p\">(</span><span class=\"n\">response</span><span class=\"p\">)</span>\n        <span class=\"bp\">self</span><span class=\"o\">.</span><span class=\"n\">fetch_impl</span><span class=\"p\">(</span><span class=\"n\">request</span><span class=\"p\">,</span> <span class=\"n\">handle_response</span><span class=\"p\">)</span>\n        <span class=\"k\">return</span> <span class=\"n\">future</span>\n\n<span class=\"k\">def</span> <span class=\"nf\">fetch_impl</span><span class=\"p\">(</span><span class=\"bp\">self</span><span class=\"p\">,</span> <span class=\"n\">request</span><span class=\"p\">,</span> <span class=\"n\">callback</span><span class=\"p\">):</span>\n        <span class=\"k\">raise</span> <span class=\"ne\">NotImplementedError</span><span class=\"p\">()</span>\n</pre></div>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/alex8224", 
        "name": "alex8224", 
        "avatar": "https://cdn.v2ex.com/avatar/7ffb/18ac/17501_large.png?m=1736415336"
      }, 
      "url": "https://www.v2ex.com/t/248278", 
      "title": "gtornado - tornado \u4e2d pymysql, pymemcache, storm orm \u652f\u6301\u5e93", 
      "id": "https://www.v2ex.com/t/248278", 
      "date_published": "2016-01-04T10:05:05+00:00", 
      "content_html": "<p>\u76ee\u524d\u9002\u914d\u4e86 pymysql, pymemcache \u548c storm \u7684\u5f02\u6b65\u5316\u652f\u6301.</p>\n\n<p>\u66f4\u591a\u8be6\u7ec6\u4fe1\u606f\u53ef\u8bbf\u95ee: <a target=\"_blank\" rel=\"nofollow\" href=\"https://github.com/alex8224/gtornado\">https://github.com/alex8224/gtornado</a></p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/mywaiting", 
        "name": "mywaiting", 
        "avatar": "https://cdn.v2ex.com/avatar/4f87/658e/1340_large.png?m=1733248338"
      }, 
      "url": "https://www.v2ex.com/t/239245", 
      "title": "Tornado \u5982\u4f55\u7ec4\u7ec7\u4e2d\u5927\u578b\u9879\u76ee\uff0c\u4f60\u4eec\u90fd\u662f\u600e\u4e48\u6837\u505a\u7684\uff1f", 
      "id": "https://www.v2ex.com/t/239245", 
      "date_published": "2015-11-26T14:24:16+00:00", 
      "content_html": "\u7528\u4e86 tornado \u4e5f\u5199\u7f51\u7ad9\uff0c\u65e0\u5b83\uff0c\u5f53\u521d\u5c31\u662f\u56e0\u4e3a\u559c\u6b22\uff0c\u56e0\u4e3a tornado \u7684\u4ee3\u7801\u5199\u5f97\u771f\u5fc3\u6f02\u4eae\u3002\r<br />\r<br />\u4e00\u5f00\u59cb\u6211\u662f\u8fd9\u6837\u7ec4\u7ec7\u9879\u76ee\u7684\uff0c\u4f60\u6ca1\u6709\u770b\u9519\uff0c\u771f\u5fc3\u53ea\u6709\u8fd9\u51e0\u4e2a\u6587\u4ef6\uff1a\r<br />\r<br />+ project\r<br />| - app.py \uff08\u57fa\u672c\u6240\u6709\u7684 handler \u90fd\u5728\u8fd9\u91cc\u4e86\uff09\r<br />| - models.py \uff08\u6570\u636e\u5e93\u76f8\u5173\u7684\uff09\r<br />| + templates \r<br />| + static\r<br />\r<br />\u5982\u679c\u8981\u7ed9\u4e2a\u53c2\u8003\u4f8b\u5b50\uff0c\u90a3 BT \u5927\u5927\u7684\u9879\u76ee\u6765\u53c2\u8003\u5427 <a target=\"_blank\" href=\"https://github.com/finiteloop/socialcookbook\" rel=\"nofollow\">https://github.com/finiteloop/socialcookbook</a> \u521a\u521a\u5f00\u59cb\u5199 tornado \u7684\u9879\u76ee\u7684\u65f6\u5019\u6ca1\u6709\u90a3\u4e48\u591a\u7684\u4e1c\u897f\uff0c\u4e00\u5207\u90fd\u5f88\u7b80\u6d01\u5f88\u7f8e\u597d\uff01\r<br />\r<br />\u7136\u540e\u5462\uff0c\u9879\u76ee\u8d8a\u6765\u8d8a\u591a\u529f\u80fd\u4e86\uff0c\u9700\u8981\u7ec4\u7ec7\u7684\u4ee3\u7801\u8d8a\u6765\u8d8a\u591a\uff0c\u9700\u8981 Seesion \uff0c\u9700\u8981 form \u68c0\u9a8c\u7b49\u4e00\u5806\u4e1c\u897f\uff0c\u4e8e\u662f\u91cd\u6784\u4e3a\u8fd9\u6837\u6765\u7ec4\u7ec7\u9879\u76ee\uff1a\r<br />\r<br />+ project\r<br />| + controllers\r<br />| | - acontroller.py\r<br />| | - bcontroller.py\r<br />| | ....\r<br />| + models\r<br />| | - amodel.py\r<br />| | - bmodel.py\r<br />| | ....\r<br />| + templates\r<br />| + forms\r<br />| | - aform.py\r<br />| | - bform.py\r<br />| | ....\r<br />| + helpers\r<br />| | - ahelper.py\r<br />| | - bhelper.py\r<br />| | ....\r<br />| - application.py \r<br />| - urls.py\r<br />| - settings.py\r<br />\r<br />\u5f88\u76f4\u63a5\u4e5f\u5f88\u660e\u663e\uff0c\u8fd9\u662f\u62ff Tornado \u6765\u505a MVC \u8fd9\u9f8c\u9f8a\u7684\u4e8b\u60c5\u4e86\uff0c\u628a\u5148\u524d\u8d8a\u6765\u8d8a\u5927\u7684 app.py \u5206\u5f00\u6210 controllers \u76ee\u5f55\uff0c models \u76ee\u5f55\u9875\u4e00\u6837\uff0c\u589e\u52a0\u4e86 forms \u76ee\u5f55\u548c helpers \u76ee\u5f55\u3002 application.py \u653e\u7f6e\u6574\u4e2a project \u7684\u542f\u52a8\u3001\u5173\u95ed\uff0c URL \u653e\u5728 urls.py \uff0c settings \u561b\u5c31\u662f\u914d\u7f6e\u3002\r<br />\r<br />\u8fd9\u6837\u5b89\u597d\u8fd0\u884c\u4e86\u597d\u957f\u4e00\u6bb5\u65f6\u95f4\uff0c\u6bd5\u7adf\u4e00\u4e2a\u5c0f\u7f51\u7ad9\uff0c\u957f\u6210\u8fd9\u6837\u5df2\u7ecf\u5f88\u5bf9\u5f97\u8d77\u6211\u62ff\u7684\u5de5\u8d44\u4e86\u3002\u4f46\u662f\u8fd9\u6837\u7684\u9879\u76ee\u7ed3\u6784\u968f\u7740\u4e1a\u52a1\u7684\u589e\u591a\u611f\u89c9\u8d8a\u6765\u8d8a\u529b\u4e0d\u4ece\u5fc3\uff1a\r<br />\r<br />1 \u3001\u9996\u5148\u4e1a\u52a1\u5173\u8054\u6bd4\u8f83\u591a\uff0c\u7c7b\u4f3c\u4e8e\u95e8\u6237\u7f51\u7ad9\u90a3\u6837\u7684 CMS \u7c7b\u578b\u7684\uff0c\u8fd9\u6837\u5c31\u65e0\u6cd5\u5206\u51fa\u51e0\u4e2a\u9879\u76ee\u6765\u5e94\u7528\u4e0a\u9762\u7684\u4ee3\u7801\u7ec4\u7ec7\u4e86\u3002\r<br />2 \u3001\u5b50\u57df\u540d\u7684\u9700\u6c42\u4f17\u591a\uff0c\u57fa\u672c\u4e00\u4e2a\u5b50\u57df\u540d <a target=\"_blank\" href=\"http://a.example.com\" rel=\"nofollow\">a.example.com</a> \u548c <a target=\"_blank\" href=\"http://b.example.com\" rel=\"nofollow\">b.example.com</a> \u7684\u4ee3\u7801\u903b\u8f91\u662f\u5b8c\u5168\u4e0d\u4e00\u6837\u7684\uff0c\u4f46\u662f\u6570\u636e\u5e93\u540e\u9762\u7684\u6570\u636e\u5374\u6709\u5f88\u591a\u9700\u6c42\u91cd\u5408\u7684\u3002\u540c\u65f6\u539f\u56e0\u89c1 1 \uff0c\u53c8\u65e0\u6cd5\u5206\u51fa\u597d\u51e0\u4e2a project \u6765\u7ec4\u7ec7\u4ee3\u7801\r<br />\r<br />\u611f\u89c9\u8d8a\u6765\u8d8a\u81c3\u80bf\u7684\u4ee3\u7801\u7ed3\u6784\uff0c\u8d8a\u6765\u8d8a\u591a\u7684\u4e1c\u897f\u52a0\u5165\u5230 Tornado \u8fd9\u4e2a\u5927\u6742\u70e9\u91cc\u9762\uff0c\u611f\u89c9\u9879\u76ee\u957f\u5f97\u8d8a\u6765\u8d8a\u50cf Django \u7684\u9879\u76ee\uff0c\u4f46\u662f\u7ec4\u7ec7\u5374\u8fdc\u4e0d\u5982 Django \u7684\u9879\u76ee\u7ec4\u7ec7\u5f97\u597d\uff01\r<br />\r<br />\u770b\u4e86\u4e00\u4e0b Flask \u7684 Blueprint \uff0c\u8fd9\u8d27\u8c8c\u4f3c\u5728\u67b6\u6784\u5927\u578b\u9879\u76ee\u7684\u65f6\u5019\u5f88\u5b9e\u7528\u7684\u6837\u5b50\u3002\r<br />\r<br />\u5c31\u50cf\u8fd9\u7bc7\u6587\u7ae0 <a target=\"_blank\" href=\"https://spacewander.github.io/explore-flask-zh/7-blueprints.html\" rel=\"nofollow\">https://spacewander.github.io/explore-flask-zh/7-blueprints.html</a> \u8bf4\u5230\u7684\u6309\u7167\u529f\u80fd(functional)\u6216\u8005\u5206\u533a(divisional)\u6765\u7ec4\u7ec7\u4ee3\u7801\u3002\r<br />\r<br />\u6309\u7167 \u5206\u533a(divisional) \u6765\u7ec4\u7ec7\u4ee3\u7801\u8c8c\u4f3c\u6709\u5929\u751f\u7684\u9002\u5408\u5927\u578b\u7684\u4e14\u5185\u90e8\u53ef\u4ee5\u677e\u8026\u5408\u7684\u9879\u76ee\uff0c\u800c\u7c7b\u4f3c\u6211\u4e0a\u9762\u7684 \u6309\u7167\u529f\u80fd(functional) \u6765\u7ec4\u7ec7\u9879\u76ee\u5c31\u9002\u5408\u7ec4\u7ec7\u529f\u80fd\u76f8\u5bf9\u5185\u805a\u7684\u9879\u76ee\u3002\r<br />\r<br />\u6309\u7167\u6211\u8fd9\u4e48\u91cd\u6784\u4e0b\u53bb\uff0c\u8fdf\u65e9\u8981\u5f04\u4e2a Django \u51fa\u6765\u7684\u611f\u89c9\u3002\u6709\u70b9\u540e\u6094\u5f53\u521d\u600e\u4e48\u4e0d\u76f4\u63a5\u7528 Django \u800c\u7528\u4e0a\u4e86 Tornado \u6765\u81ea\u5df1\u9020\u5404\u79cd\u8f6e\u5b50\u3002\r<br />\r<br />\u5404\u4f4d\u5728\u67b6\u6784 Tornado \u7684\u4e2d\u5927\u578b\u9879\u76ee\uff0c\u6709\u4ec0\u4e48\u7ecf\u9a8c\u53ef\u4ee5\u5206\u4eab\u5417\uff1f\r<br />\r<br />\u8c22\u8c22\uff01"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/lydhr", 
        "name": "lydhr", 
        "avatar": "https://cdn.v2ex.com/avatar/5bff/155d/76751_large.png?m=1668374122"
      }, 
      "url": "https://www.v2ex.com/t/238241", 
      "title": "tornado \u8dd1\u4e0d\u901a\uff0c\u5c0f\u767d\u6c42\u5e2e\u5fd9", 
      "id": "https://www.v2ex.com/t/238241", 
      "date_published": "2015-11-23T06:16:10+00:00", 
      "content_html": "<p>Context \uff1a<br>\n- tornado \u7684 helloWorld \u6559\u7a0b\u4ee3\u7801\u8dd1\u4e0d\u901a\uff0c localhost:8000 \u4f1a\u62a5\u9519\u2018\u672a\u6536\u5230\u6570\u636e\u2019<br><br>\n- \u672c\u673a\u5e76\u672a\u88c5 Nginx \uff0c\u4f46\u662f 0.0.0.0 \u6253\u5f00\u540e\u4f1a\u663e\u793a Welcome to nginx!\u90a3\u4e2a\u6b22\u8fce\u9875<br><br>\n- terminal \u4e2d\uff0c nginx command not found<br><br>\nQuestion \uff1a<br>\n- \u5982\u4f55\u5b9a\u4f4d\u81ea\u5df1\u7684 nginx \u8f6c\u5230\u54ea\u91cc\u4e86\uff1f<br>\n- tornado \u7684 helloWorld \u54ea\u91cc\u4e0d\u5bf9\uff1f</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/Gem", 
        "name": "Gem", 
        "avatar": "https://cdn.v2ex.com/gravatar/4506e57d77d4bba333eaa2c9ba89551c?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/234457", 
      "title": "Tornado 4.3 \u53d1\u5e03", 
      "id": "https://www.v2ex.com/t/234457", 
      "date_published": "2015-11-07T11:53:58+00:00", 
      "content_html": "Highlights: The new async/await keywords in Python 3.5 are supported. \r<br />\r<br />In most cases, async def can be used in place of the @<a target=\"_blank\" href=\"/member/gen\">gen</a>.coroutine decorator. Inside a function defined with async def, use await instead of yield to wait on an asynchronous operation. Coroutines defined with async/await will be faster than those defined with @<a target=\"_blank\" href=\"/member/gen\">gen</a>.coroutine and yield.\r<br />\r<br />But do not support some features including Callback/Wait or the ability to yield a Twisted Deferred. See the users \u2019 guide for more.\r<br />\r<br />\r<br /><a target=\"_blank\" href=\"http://www.tornadoweb.org/en/stable/releases/v4.3.0.html\" rel=\"nofollow\">http://www.tornadoweb.org/en/stable/releases/v4.3.0.html</a>"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/Gem", 
        "name": "Gem", 
        "avatar": "https://cdn.v2ex.com/gravatar/4506e57d77d4bba333eaa2c9ba89551c?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/233912", 
      "title": "Tornado \u5b98\u65b9\u600e\u4e48\u4e0d\u597d\u597d\u7ef4\u62a4\u4e00\u4e2a sql \u7684\u5f02\u6b65\u6570\u636e\u5e93\u9a71\u52a8\uff1f", 
      "id": "https://www.v2ex.com/t/233912", 
      "date_published": "2015-11-05T09:18:38+00:00", 
      "content_html": "\u867d\u7136\u8fd9\u6837\u663e\u5f97 Tornado \u66f4\u52a0\u7eaf\u7cb9\u4e86\uff0c\u53ef\u662f\u5728\u7528\u6237\u5b9e\u9645\u4f7f\u7528\u8d77\u6765\uff0c\u8fd8\u662f\u6709\u5f88\u591a\u4e0d\u4fbf\uff0c\u793e\u533a\u91cc\u9762\u4e5f\u6ca1\u6709\u6bd4\u8f83\u9ad8 star \u7684\u5b9e\u73b0\u3002"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/dai269619118", 
        "name": "dai269619118", 
        "avatar": "https://cdn.v2ex.com/avatar/8f4d/e6d2/40453_large.png?m=1750644025"
      }, 
      "url": "https://www.v2ex.com/t/228298", 
      "date_modified": "2015-10-15T08:30:11+00:00", 
      "content_html": "<div class=\"highlight\"><pre>def get(self):\n    time.sleep(100)\n    self.write(&#39;hello test&#39;)\n</pre></div>\n\n<p>\u5982\u679c\u7a0b\u5e8f\u6267\u884c\u7684\u65f6\u5019\u4e2d\u95f4\u5904\u7406\u4e00\u4e2a\u9700\u8981\u5f88\u591a\u65f6\u95f4\uff0c\u8fd9\u4e2a\u65f6\u5019\u6709\u4e00\u4e2a\u65b0\u7684\u8bf7\u6c42<br>\n\u90a3\u4e48\u7b2c\u4e8c\u4e2a\u8bf7\u6c42\u9700\u8981\u7b49\u5f85\u7b2c\u4e00\u4e2a\u8bf7\u6c42\u6267\u884c\u5b8c\u624d\u5f00\u59cb\u6267\u884c\u7b2c\u4e8c\u4e2a\u64cd\u4f5c<br>\n\u63a5\u7740\u7528 nginx \u505a\u4e86\u4e00\u4e2a\u8d1f\u8f7d\u5747\u8861\uff0c\u5f00\u4e86 3 \u4e2a tornado</p>\n<div class=\"highlight\"><pre>upstream to.com{\n        server 127.0.0.1:8887;\n        server 127.0.0.1:8888;\n        server 127.0.0.1:8889;\n    }\n</pre></div>\n\n<p>\u53ef\u662f\u4e2d\u95f4\u8fd8\u662f\u6709\u673a\u7387\u5207\u5230\u540c\u4e00\u4e2a\u7aef\u53e3\u4e0a\u9762\uff0c\u7136\u540e\u53c8\u8981\u7b49\u5f85\u5904\u7406\uff0c\u6709\u4ec0\u4e48\u5176\u4ed6\u5904\u7406\u65b9\u9762\u5417\uff1f</p>\n", 
      "date_published": "2015-10-15T08:11:43+00:00", 
      "title": "\u5173\u4e8e tornado \u963b\u585e\u7684\u95ee\u9898", 
      "id": "https://www.v2ex.com/t/228298"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/sujin190", 
        "name": "sujin190", 
        "avatar": "https://cdn.v2ex.com/avatar/e66f/964a/36127_large.png?m=1732868751"
      }, 
      "url": "https://www.v2ex.com/t/226295", 
      "title": "tornado \u7684 mysql \u5f02\u6b65\u9a71\u52a8\u6027\u80fd\u6d4b\u8bd5", 
      "id": "https://www.v2ex.com/t/226295", 
      "date_published": "2015-10-08T05:50:58+00:00", 
      "content_html": "<div><a target=\"_blank\" href=\"https://gist.github.com/mosquito/aa20b94fec8b406d9a51\" target=\"_blank\">https://gist.github.com/mosquito/aa20b94fec8b406d9a51</a> <button onclick=\"lazyGist(this)\">&nbsp;\u663e\u793a Gist \u4ee3\u7801&nbsp;</button></div>"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/sujin190", 
        "name": "sujin190", 
        "avatar": "https://cdn.v2ex.com/avatar/e66f/964a/36127_large.png?m=1732868751"
      }, 
      "url": "https://www.v2ex.com/t/219815", 
      "title": "pypy \u4e4b tornado", 
      "id": "https://www.v2ex.com/t/219815", 
      "date_published": "2015-09-10T15:24:11+00:00", 
      "content_html": "\u5728 pypy \u4e0b\u6d4b\u8bd5\u4e86\u4e0b tornado \uff0c\u6ca1\u6709\u6570\u636e\u5e93\u7684\u60c5\u51b5\u4e0b ab -c1000 \u53ef\u4ee5\u8dd1\u5230 20000 \u591a qps \uff0c\u5e26 mysql \u67e5\u8be2\u5355\u884c\u4e24\u4e2a\u5b57\u6bb5\u7684\u6570\u636e\u4e5f\u80fd\u8dd1\u5230 1000 \u5de6\u53f3 qps \uff0c pypy \u5bf9 torndao \u7684\u63d0\u5347\u8fd8\u662f\u633a\u591a\u7684\u554a\u3002\r<br />\u4f7f\u7528\u7684\u662f\u5b98\u7f51\u7684\u793a\u4f8b\uff0c i5 \u56db\u6838 8g \uff0c mysql \u9ed8\u8ba4\u914d\u7f6e"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/xlzd", 
        "name": "xlzd", 
        "avatar": "https://cdn.v2ex.com/avatar/fa99/2dd3/108641_large.png?m=1459071920"
      }, 
      "url": "https://www.v2ex.com/t/211788", 
      "date_modified": "2015-08-08T11:28:51+00:00", 
      "content_html": "<p>\u8bf7\u95ee\u5404\u4f4d, \u670d\u52a1\u5668\u7aef\u7528\u7684tornado, \u5047\u5982\u51e0\u4e2adomain\u90fd\u6307\u5411\u4e86\u540c\u4e00\u4e2a\u5730\u5740, \u5e94\u8be5\u600e\u4e48\u5f97\u5230\u88ab\u8bbf\u95ee\u7684\u57df\u540d\u5462?</p>\n", 
      "date_published": "2015-08-08T11:19:47+00:00", 
      "title": "tornado \u591a\u4e2a url", 
      "id": "https://www.v2ex.com/t/211788"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/roychan", 
        "name": "roychan", 
        "avatar": "https://cdn.v2ex.com/gravatar/81a46497b9e8abce7479fe40d7bf8f7b?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/208772", 
      "date_modified": "2015-07-27T15:45:41+00:00", 
      "content_html": "<p>\u521a\u521a\u5f00\u59cb\u7528 Tornado\u3002</p>\n\n<p>\u5728\u7528\u6237\u8ba4\u8bc1\u65f6\uff0c\u6211\u8986\u5199\u4e86 BaseHandler\uff0c\u4ee5\u4fbf\u4f7f\u7528\u5185\u7f6e\u7684 current_user() \u65b9\u6cd5\u4e0e is_authenticated \u4fee\u9970\u5668\u3002</p>\n<div class=\"highlight\"><pre>class BaseHandler(tornado.web.RequestHandler):\n    def get_current_user(self):\n        return self.get_secure_cookie(&#39;user&#39;)\n</pre></div>\n\n<p>\u5728\u67d0\u6b65\u4e2d\uff0c\u6211\u52a0\u4e86\u5224\u65ad if self.current_user then xxx\uff0c\u6b64\u65f6\u5373\u4fbf\u767b\u5f55\u4e86\u4e5f\u65e0\u6cd5\u6267\u884c xxx\uff0c\u5982\u679c\u6211\u628a\u5224\u65ad\u5199\u6210 if self.get_current_user then xxx\uff0c\u4fbf\u80fd\u6210\u529f\u786e\u8ba4\u767b\u5f55\uff0cxxx \u5c31\u6267\u884c\u4e86\u3002</p>\n\n<p>\u8bf7\u95ee\u8fd9\u53ef\u80fd\u662f\u4ec0\u4e48\u95ee\u9898\uff1f</p>\n", 
      "date_published": "2015-07-27T15:43:49+00:00", 
      "title": "RequestHandler \u7c7b\u7684 get_current_user() \u65b9\u6cd5\u8986\u5199\u65e0\u6548", 
      "id": "https://www.v2ex.com/t/208772"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/agentwx", 
        "name": "agentwx", 
        "avatar": "https://cdn.v2ex.com/avatar/228e/bc0d/78510_large.png?m=1468483025"
      }, 
      "url": "https://www.v2ex.com/t/206354", 
      "title": "tornado \u52a8\u6001\u6dfb\u52a0 url \u7684\u95ee\u9898", 
      "id": "https://www.v2ex.com/t/206354", 
      "date_published": "2015-07-17T05:04:14+00:00", 
      "content_html": "<p>\u6700\u8fd1\u5728\u770btornado \uff0c \u770b\u5230\u5b83\u7684url\u7684\u5904\u7406\u65b9\u5f0f\uff0c\u4e00\u822c\u662furl(r&quot;/path&quot;,sthhandler),\u7a81\u7136\u5fc3\u91cc\u60f3\u5230\u80fd\u4e0d\u80fd\u76f4\u63a5\u52a8\u6001\u521b\u5efa\u8fd9\u4e2aurl\uff0csthhandler\u4e00\u822c\u90fd\u662f\u4e00\u4e2a\u7c7b\uff0c\u5982\u679c\u52a8\u6001\u521b\u5efa\u4e86\u4e00\u4e2aurl, \u76f8\u5e94\u7684handler\u5982\u4f55\u52a8\u6001\u751f\u6210\u5462\uff1f \u76f4\u63a5\u4ee5py\u6587\u4ef6\u7684\u5f62\u5f0f\u751f\u6210\uff1f</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/evolsnow", 
        "name": "evolsnow", 
        "avatar": "https://cdn.v2ex.com/avatar/ae52/b061/29293_large.png?m=1472388707"
      }, 
      "url": "https://www.v2ex.com/t/199922", 
      "date_modified": "2015-06-19T13:40:40+00:00", 
      "content_html": "<p>\u5728/test\u7684handler\u6dfb\u52a0\u4e86@tornado.web.authenticated, \u672a\u767b\u5f55\u8bbf\u95ee\u65f6\u8df3\u8f6c\u5230\u8bbe\u7f6e\u7684/login.<br>\n\u6b64\u65f6\u7f51\u5740\u4e3a&quot;/login?next=%2Ftest&quot;, \u867d\u7136\u8bbe\u7f6e\u4e86:self.redirect(self.get_argument(&quot;next&quot;, &quot;/&quot;))<br>\n\u4f46\u662f\u767b\u5f55\u540e\u4e0d\u8fd4\u56de\u81f3&quot;/test&quot;\u800c\u662f\u5230\u4e86\u9ed8\u8ba4\u7684&quot;/&quot;\u9875\u9762</p>\n\n<p>\u7f51\u4e0a\u641c\u7d22\u65e0\u679c,\u95ee\u9898\u548c\u8fd9\u5927\u54e5\u4e00\u6837:<br>\n<a target=\"_blank\" rel=\"nofollow\" href=\"http://stackoverflow.com/questions/20290020/tornado-next-query-string-url-parameter\">http://stackoverflow.com/questions/20290020/tornado-next-query-string-url-parameter</a><br>\n\u4e0d\u8fc7\u8be5\u7b54\u6848\u5e76\u672a\u89e3\u51b3\u95ee\u9898, \u6240\u4ee5\u7ee7\u7eed\u6765v\u7ad9\u6c42\u89e3</p>\n", 
      "date_published": "2015-06-19T13:38:40+00:00", 
      "title": "tornado \u600e\u4e48\u5229\u7528'next'\u53c2\u6570\u8fdb\u884c\u9875\u9762\u8df3\u8f6c", 
      "id": "https://www.v2ex.com/t/199922"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/wolegequ", 
        "name": "wolegequ", 
        "avatar": "https://cdn.v2ex.com/gravatar/51bcbbe0ce50821e1aedd9c1c1c9e674?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/199311", 
      "title": "finish() called twice", 
      "id": "https://www.v2ex.com/t/199311", 
      "date_published": "2015-06-17T09:18:49+00:00", 
      "content_html": "\u62b1\u6b49,\u6807\u9898\u7565\u542b\u7cca.\r<br />\r<br />\u6709\u4e24\u4e2a\u8fd4\u56dejson\u63a5\u53e3\r<br /><a target=\"_blank\" href=\"http://example.com/api/user/uid\" rel=\"nofollow\">http://example.com/api/user/uid</a>\r<br /><a target=\"_blank\" href=\"http://example.com/api/user/uid/fun\" rel=\"nofollow\">http://example.com/api/user/uid/fun</a>\r<br />\r<br />\u672c\u6253\u7b97\u5982\u6b64\u5b9e\u73b0 handles \r<br />(r'/api/user/(.*)',          user.fun1),\r<br />(r'/api/user/(.*)/fun2',  user.fun2 ),\r<br />\r<br />\u641e\u4e86\u534a\u5929,\u53d1\u73b0 user.fun1 \u6839\u672c\u4e0d\u4f1a\u8c03\u7528 ......\r<br />\r<br />\u4e8e\u662f\u4e4e\u6539\u4e3a\u8fd9\u6837\r<br />\r<br />(r'/api/user/(.*)',          user.funs ),\r<br />\r<br />\r<br /> class funs(BaseController):\r<br />  \r<br />          @<a target=\"_blank\" href=\"/member/tornado\">tornado</a>.web.asynchronous\r<br />          def get(self, params):\r<br />                        \r<br />                        if 'fun' in params:\r<br />                                  self.fun2\r<br />                        else:\r<br />                                  self.fun1\r<br />\r<br />\u60ca\u5947\u7684\u53d1\u73b0 it works !!!(\u867d\u7136\u5f88\u5c71\u5be8...)\r<br />\r<br />\u91cd\u70b9\u6765\u4e86 !!!!\r<br />\r<br />\u5ba2\u6237\u7aef\u4e24\u4e2a\u63a5\u53e3\u5148\u540e\u51e0\u4e4e\u540c\u65f6\u8bf7\u6c42\r<br />\r<br />self.fun1 self.fun2\u6700\u540e\u90fd\u4f1a\u8c03\u7528 self.finish(),\r<br />\r<br />\u4e8e\u662f\u4e4e\u51fa\u73b0\u4e86 finish() called twice - - !\r<br />\r<br />\u540e\u6765\u770b\u5230\u6709\u8bf4\u6cd5@<a target=\"_blank\" href=\"/member/tornado\">tornado</a>.web.asynchronous \u662f\u4e0d\u53ef\u4ee5self.finish()\u7684\r<br />\r<br />\u4e8e\u662f\u4e4e\u6539\u4e3aself.fun1 self.fun2\u6700\u540e\u90fd\u8c03\u7528 self.write(),\r<br />\r<br />\u6ca1\u6709 finish() called twice\u4e86,\u4f46\u662f\u6709\u4e00\u4e2a\u63a5\u53e3\u4e00\u76f4\u6ca1\u6570\u636e\u8fd4\u56de(\u5355\u72ec\u8bf7\u6c42\u4efb\u610f\u4e00\u4e2a\u90fd\u6b63\u5e38!)\r<br />\r<br />\u9189\u4e86\u9189\u4e86...."
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/wingyiu", 
        "name": "wingyiu", 
        "avatar": "https://cdn.v2ex.com/avatar/691e/fa33/46559_large.png?m=1445329049"
      }, 
      "url": "https://www.v2ex.com/t/195754", 
      "title": "\u963f\u91cc\u4e91 ECS 1CPU 1G 1Mbs \u8dd1 tornado \u5f00\u591a\u5c11\u8fdb\u7a0b\u5408\u9002\uff1f", 
      "id": "https://www.v2ex.com/t/195754", 
      "date_published": "2015-06-03T04:00:12+00:00", 
      "content_html": "\u5982\u9898,nginx+3tornado\u53ea\u8dd1\u4e8630RPS\uff0c\u600e\u4e48\u7834\uff1f\u6b63\u5e38\u4e0d\uff1f"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/tornadoxyz", 
        "name": "tornadoxyz", 
        "avatar": "https://cdn.v2ex.com/gravatar/30c91d8f7e9b82311fbf305ea4983128?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/192095", 
      "title": "tornado.locale.format_date()\u7684\u65e5\u671f\u6c49\u5316\u95ee\u9898", 
      "id": "https://www.v2ex.com/t/192095", 
      "date_published": "2015-05-19T01:08:12+00:00", 
      "content_html": "\u5728Introduction to tornado\u4e00\u4e66\u4e2d\uff0c\u4f7f\u7528\r<br />```\r<br />{{ locale.format_date() }} \r<br />```\r<br />\u51fd\u6570\u5bf9\u65f6\u95f4\u6233\u8fdb\u884c\u8f6c\u5316\uff0c\u53ef\u662f\u8f6c\u6362\u540e\u7684\u7ed3\u679c\u4e3a\u82f1\u6587\u7684\uff0c\u4f8b\u5982 2 seconds ago\uff0c\u6709\u6ca1\u6709\u65b9\u6cd5\u5c06\u5176\u6c49\u5316\u4e3a\u4e2d\u6587\u5462\uff1f\u7c97\u7565\u7684\u770b\u8fc7tornado.locale\u6a21\u5757\u7684\u6e90\u7801\uff0c\u53ef\u8fd8\u662f\u4e00\u5934\u96fe\u6c34\u3002\u671b\u5404\u4f4d\u670b\u53cb\u4e0d\u541d\u8d50\u6559\u3002"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/waynee", 
        "name": "waynee", 
        "avatar": "https://cdn.v2ex.com/avatar/5dd3/b684/38050_large.png?m=1426133920"
      }, 
      "url": "https://www.v2ex.com/t/190156", 
      "date_modified": "2022-03-21T05:16:23+00:00", 
      "content_html": "\u6700\u8fd1\u5728\u5b66\u4e60Tornado\uff0c\u5728\u5199\u5206\u9875\u7684\u65f6\u5019\u9047\u5230\u4e86\u74f6\u9888\u3002\r<br />\u662f\u53c2\u7167\u8fd9\u4e2a\u95ee\u7b54\u8fdb\u884c\u5199\u7684\uff1a\r<br /><a target=\"_blank\" href=\"http://stackoverflow.com/questions/15981257/can-tornado-handle-pagination\" rel=\"nofollow\">http://stackoverflow.com/questions/15981257/can-tornado-handle-pagination</a>\r<br />\r<br />\u8def\u5f84\u5c31\u662f\uff1a(r&quot;/&quot;,MainHandler)\r<br />\r<br />\u903b\u8f91\u662f\uff1a\r<br />class MainHandler(BaseHandler):\r<br />    def get(self,template_variables = {}):\r<br />        news_timeline = self.news_model.get_all_news() \uff03\u83b7\u53d6\u6240\u6709news\r<br />        current_page = int(self.get_argument('page',0)) \uff03 \u83b7\u53d6\u5f53\u524dURL\u91cc\u7684page\u53c2\u6570\r<br />        template_variables[&quot;news_timeline&quot;] = news_timeline\r<br />        template_variables[&quot;current_page&quot;] = current_page\r<br />        self.render(&quot;index.html&quot;,**template_variables)\r<br />\r<br />HTMl\u662f\uff1a\r<br />&lt;body&gt;\r<br />{% for news in news_timeline %}\r<br />&lt;a href = &quot;{{ news[&quot;news_link&quot;] }}&quot;&gt;{{ news[&quot;news_name&quot;] }}&lt;/a&gt;\r<br />{% end %}\r<br />{% module Paginator(current_page,5, len(news_timeline)) %}\r<br />&lt;/body&gt;\r<br />\r<br />\u4f46\u662f\u5e95\u90e8\u7684\u5206\u9875\u94fe\u63a5\u80fd\u591f\u663e\u793a\u51fa\u6765\uff0c\u53ef\u662f\u6240\u6709\u7ed3\u679c\u90fd\u663e\u793a\u5728\u4e86\u4e00\u4e2a\u9875\u9762\uff0c\u5e76\u6ca1\u6709\u5206\u5f00\u663e\u793a\u3002\u73b0\u5728\u627e\u4e0d\u5230\u95ee\u9898\u5728\u54ea\u91cc\uff0c\u662f\u6211\u5c11\u4e9b\u4e86\u4ec0\u4e48\u4ee3\u7801\u5417\uff1f\r<br />\r<br />\u5404\u4f4d\u5927\u795e\uff0c\u6c42\u6559\uff01\uff01\uff01", 
      "date_published": "2015-05-11T06:12:52+00:00", 
      "title": "Tornado \u5206\u9875\u95ee\u9898\u6c42\u89e3\uff01", 
      "id": "https://www.v2ex.com/t/190156"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/Emory_M", 
        "name": "Emory_M", 
        "avatar": "https://cdn.v2ex.com/avatar/310d/cbbf/333_large.png?m=1611546038"
      }, 
      "url": "https://www.v2ex.com/t/183039", 
      "title": "Tornado \u5f00\u53d1\u4e2d\u51fa\u9519\u8c03\u8bd5\u5982\u4f55\u50cf PHP \u4e00\u6837\uff1f", 
      "id": "https://www.v2ex.com/t/183039", 
      "date_published": "2015-04-11T05:45:36+00:00", 
      "content_html": "php\u5f00\u53d1\u7684\u65f6\u5019\u56e0\u4e3aCGI\u7ba1\u7406\u548cphp\u89e3\u91ca\u5668\u662f\u72ec\u7acb\u7684\uff0c\u6240\u4ee5HTTP\u670d\u52a1\u4e0d\u4f1a\u56e0\u4e3a\u9519\u8bef\u800c\u6302\u6389\uff0c\u53ea\u8981\u4fee\u6539\u597d\u4ee3\u7801\u5237\u65b0\u9875\u9762\u5c31\u884c<br /><br />\u4f46\u662fTornado\u6216Python Web\u5f00\u53d1\u4e2d\u5982\u679c\u9047\u5230\u9519\u8bef\u8fdb\u7a0b\u9000\u51fa\uff0c\u90fd\u9700\u8981\u4fee\u6539\u4ee3\u7801\u540e\u624b\u52a8\u91cd\u542f\u8fdb\u7a0b\uff0c\u4f53\u9a8c\u975e\u5e38\u4e0d\u597d<br /><br />Node.js\u53ef\u4ee5\u4f7f\u7528cluster\u6765\u542f\u52a8\u5b50\u8fdb\u7a0b\u7ba1\u7406\uff0c \u5b9e\u73b0\u201c\u51fa\u9519-\u76d1\u63a7\u4ee3\u7801\u4fee\u6539-\u91cd\u542f\u8fdb\u7a0b\u201d<br />\u6bd4\u5982\uff1a <a target=\"_blank\" href=\"https://github.com/DoubleSpout/ClusterPlus\" rel=\"nofollow\">https://github.com/DoubleSpout/ClusterPlus</a><br /><br />Tornado\u7684tornado.autoreload\u6a21\u5757\u4f3c\u4e4e\u53ea\u80fd\u5904\u7406import-time\u53d1\u751f\u7684\u8bed\u6cd5\u9519\u8bef\uff0c\u5e76\u4e0d\u80fd\u6301\u7eed\u8fdb\u5165wait\u76d1\u63a7<br /><br />\u8bf7\u6559\u4e00\u4e0bTornado\u4e0b\u7684\u89e3\u51b3\u601d\u8def"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/guoran728", 
        "name": "guoran728", 
        "avatar": "https://cdn.v2ex.com/gravatar/00fbc3492e0aaea7ca35ab29f3279fde?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/182595", 
      "date_modified": "2015-04-09T08:01:28+00:00", 
      "content_html": "<p>\u5b98\u65b9\u4f8b\u5b50:</p>\n\n<p>from tornado.concurrent import Future</p>\n\n<p>def async_fetch_future(url):<br>\n    http_client = AsyncHTTPClient()<br>\n    my_future = Future()<br>\n    fetch_future = http_client.fetch(url)<br>\n    fetch_future.add_done_callback(<br>\n        lambda f: my_future.set_result(f.result()))<br>\n    return my_future<br>\n\u4ec0\u4e48\u534f\u7a0b,\u5f02\u6b65\u8ff7\u8ff7\u7cca\u7cca\u7684!</p>\n\n<p>\u5b8c\u5168\u4e0d\u61c2 my_future = Future() \u4e3a\u4ec0\u4e48\u8981\u751f\u6210\u4e2a Future \u5bf9\u8c61,\u6700\u540e\u53c8\u8fd4\u56de\u5b83\uff01\uff01\u5df2\u7ecf\u75db\u82e6\u4e86\u51e0\u5929\u4e86\uff01\uff01\u5927\u795e\u6765\u89e3\u6551\u4e0b\u6211\u5427</p>\n", 
      "date_published": "2015-04-09T07:33:06+00:00", 
      "title": "\u65b0\u624b\u5b8c\u5168\u4e0d\u61c2 tornado.concurrent.Future", 
      "id": "https://www.v2ex.com/t/182595"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/waynee", 
        "name": "waynee", 
        "avatar": "https://cdn.v2ex.com/avatar/5dd3/b684/38050_large.png?m=1426133920"
      }, 
      "url": "https://www.v2ex.com/t/182359", 
      "date_modified": "2015-04-08T19:41:36+00:00", 
      "content_html": "RT\uff0c\u505a\u4e00\u4e2a\u8c03\u67e5\u3002<br /><a target=\"_blank\" href=\"http://learntornado.launchrock.com/\" rel=\"nofollow\">http://learntornado.launchrock.com/</a>", 
      "date_published": "2015-04-08T08:52:02+00:00", 
      "title": "\u6709\u591a\u5c11\u4eba \u6709\u4ed8\u8d39\u5b66\u4e60 Tornado \u7684\u610f\u613f\uff0c\u8fd9\u662f\u4e00\u4e2a\u5b66\u4e60\u7f51\u7ad9\u3002", 
      "id": "https://www.v2ex.com/t/182359"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/waynee", 
        "name": "waynee", 
        "avatar": "https://cdn.v2ex.com/avatar/5dd3/b684/38050_large.png?m=1426133920"
      }, 
      "url": "https://www.v2ex.com/t/176237", 
      "title": "\u8bf7\u95ee\u4e0b tornado \u5728 ios app \u540e\u53f0\u65b9\u9762\u6709\u6210\u719f\u7684\u5b9e\u73b0\u5417\uff1f", 
      "id": "https://www.v2ex.com/t/176237", 
      "date_published": "2015-03-11T16:48:13+00:00", 
      "content_html": ""
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/invite", 
        "name": "invite", 
        "avatar": "https://cdn.v2ex.com/gravatar/6f923c92f2bf3bbafc1730dc412016e3?s=73&d=retro"
      }, 
      "url": "https://www.v2ex.com/t/172965", 
      "title": "\u65b0\u624b\u6c42\u6559\u5173\u4e8e Tornado + SQLite \u7684\u4e24\u4e2a\u95ee\u9898", 
      "id": "https://www.v2ex.com/t/172965", 
      "date_published": "2015-02-26T08:22:28+00:00", 
      "content_html": "<p>\u76ee\u524d\u7684\u60c5\u51b5\u662f\uff0c\u4e00\u4e2a Tornado \u8fdb\u7a0b\uff0c \u7136\u540e\u6309\u6211\u7684\u7406\u89e3\uff0c\u8bf7\u6c42\u6765\u4e86\u4ee5\u540e\uff0c\u4f1a\u81ea\u5df1\u5f00\u7ebf\u7a0b\u5904\u7406\u7684\u3002 \u90a3\u4e48\u95ee\u9898\u6765\u4e86\uff1a</p>\n\n<p>1\u3001\u591a\u4e2a\u8fdb\u7a0b\u540c\u65f6\u8bfb\u53d6SQLite\uff0c\u4f1a\u6709\u9501\u5b9a\u4e48\uff1f \u7f51\u4e0a\u8bf4\u591a\u4e2a\u8fdb\u7a0b\u53ef\u4ee5\u540c\u65f6\u8bfb\u5199\uff0c\u4f46\u8bf4\u5199\u7684\u65f6\u5019\u6709\u9501\u5b9a\uff0c\u90a3\u8bfb\u7684\u65f6\u5019\uff0c\u662f\u4e0d\u662f\u90fd\u80fd\u7acb\u9a6c\u8fd4\u56de\uff1f\u5982\u679c\u53ef\u4ee5\u7acb\u9a6c\u8fd4\u56de\uff0c \u90a3\u5e94\u8be5\u53ef\u4ee5\u5f00\u591a\u4e2a Tornado \u4e86\u5427\uff1f</p>\n\n<p>2\u3001\u591a\u4e2a\u7ebf\u7a0b\u4e4b\u95f4\uff0c\u4e0d\u80fd\u5171\u4eab\u53e5\u67c4\u4e48\uff1f\u7f51\u4e0a\u8bf4\uff0c\u591a\u7ebf\u7a0b\u4e4b\u95f4\u5171\u4eab\u53e5\u67c4\u53ef\u80fd\u5b58\u5728\u95ee\u9898\uff0c\u90a3\u591a\u7ebf\u7a0b\u67e5\u8be2\u7684\u8bdd\uff0c\u6bcf\u6b21\u8981connect\uff0c\u7136\u540e\u5728close\u4e48\uff1f \u600e\u4e48\u6837\u80fd\u5728 Tornado \u91cc\u4fdd\u6301SQLite\u7684\u957f\u8fde\u63a5\u5462\uff1f</p>\n\n<p>\u76ee\u524d\u7684\u9700\u6c42\u662f\uff1a SQLite \u53ea\u8bfb\uff0c\u6ca1\u6709\u5199\u7684\u9700\u6c42\u3002</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/Livid", 
        "name": "Livid", 
        "avatar": "https://cdn.v2ex.com/avatar/c4ca/4238/1_large.png?m=1775624785"
      }, 
      "url": "https://www.v2ex.com/t/172185", 
      "title": "Tornado 4.1", 
      "id": "https://www.v2ex.com/t/172185", 
      "date_published": "2015-02-22T10:13:58+00:00", 
      "content_html": "<a target=\"_blank\" href=\"http://www.tornadoweb.org/en/stable/releases/v4.1.0.html\" rel=\"nofollow\">http://www.tornadoweb.org/en/stable/releases/v4.1.0.html</a>"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/Livid", 
        "name": "Livid", 
        "avatar": "https://cdn.v2ex.com/avatar/c4ca/4238/1_large.png?m=1775624785"
      }, 
      "url": "https://www.v2ex.com/t/171602", 
      "title": "\u5173\u4e8e\u4f18\u96c5\u5730\u90e8\u7f72 Tornado \u65b0\u4ee3\u7801\u7684\u4e00\u79cd\u65b9\u5f0f", 
      "id": "https://www.v2ex.com/t/171602", 
      "date_published": "2015-02-17T23:28:33+00:00", 
      "content_html": "<a target=\"_blank\" href=\"http://stackoverflow.com/questions/8086885/is-there-a-way-to-deploy-new-code-with-tornado-python-without-restarting-the-ser\" rel=\"nofollow\">http://stackoverflow.com/questions/8086885/is-there-a-way-to-deploy-new-code-with-tornado-python-without-restarting-the-ser</a>"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/jecvay", 
        "name": "jecvay", 
        "avatar": "https://cdn.v2ex.com/avatar/5d88/04b8/75586_large.png?m=1668072609"
      }, 
      "url": "https://www.v2ex.com/t/170521", 
      "title": "Tornado Template \u5982\u4f55\u83b7\u5f97 JavaScript \u4e2d\u7684 var \u53d8\u91cf?", 
      "id": "https://www.v2ex.com/t/170521", 
      "date_published": "2015-02-12T09:11:58+00:00", 
      "content_html": "<p>\u6211\u60f3\u901a\u8fc7jQuery \u53d1\u8d77\u4e00\u4e2a\u5bf9api\u7684GET\u8bf7\u6c42, \u83b7\u5f97\u4e00\u4e2ajson\u683c\u5f0f\u7684list, \u7136\u540e\u7528 {% for %}\u63a7\u5236\u8bed\u53e5\u6765\u628ajson\u91cc\u9762\u7684\u6bcf\u4e00\u4e2aTitle\u7ed9\u663e\u793a\u51fa\u6765.</p>\n\n<p>\u6c42\u6559\u5982\u4f55\u5728 {% %} \u91cc\u9762\u8c03\u7528 jQuery\u83b7\u5f97\u7684data</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/pagict", 
        "name": "pagict", 
        "avatar": "https://cdn.v2ex.com/avatar/96a0/cc2f/9380_large.png?m=1572610161"
      }, 
      "url": "https://www.v2ex.com/t/164660", 
      "date_modified": "2015-01-22T16:39:42+00:00", 
      "content_html": "\u6700\u8fd1\u5728\u8ddf\u7740 Introduction to Tornado \u5b66Tornado\uff0c\u505a\u5230Chapter5 \u7684 Live Inventory Reporting \u793a\u4f8b\u7684\u65f6\u5019\uff0c\u53d1\u73b0\u6ca1\u6709\u60f3\u8981\u7684\u6548\u679c\u3002<br />\u5177\u4f53\u5c31\u662f\uff0c\u5e94\u8be5\u70b9\u4e86 Add to cart \u7684button \u540e\u4f1a\u9690\u85cf\uff0c\u6362\u4e3a Remove from cart button, \u53e6\u5916\u5c31\u662f stock left \u6570\u8981\u51cf\u5c11\u5427\uff0c\u4f46\u662f\u73b0\u5728\u5374\u90fd\u6ca1\u53cd\u5e94\u3002\u611f\u89c9\u662fjavascript \u6ca1\u6709\u6b63\u786eload\uff0c\u4f46\u662f\u5c0f\u5f1f\u53c8\u8fd8\u4e0d\u61c2javascipt\u3002\u73b0\u5728\u731c\u60f3\u662f\u4e0d\u662f\u4e66\u4e0a\u4f8b\u5b50\u8fc7\u65f6\u4e86\u7684\u539f\u56e0\uff0c\u6211\u7684\u73af\u5883\u662f\uff1apython 3.4,  tornado 4.1.dev1<br />\u6709\u54ea\u4f4d\u80fd\u5e2e\u5fd9\u770b\u4e0b\u4e48\uff1f\u4ee3\u7801\u5012\u662f\u7167\u7740\u4e66\u4e0a\u6572\u7684<br /><br />\u76ee\u5f55\u7ed3\u6784\uff1a<br /> Long Polling/<br />  |_shopping_cart.py<br />  |_static/<br />  |_ _|_scripts/<br />  |_ _ _|_inventory.js<br />  |_templates/<br />  |_ _|_index.html", 
      "date_published": "2015-01-22T16:38:25+00:00", 
      "title": "\u5b66\u4e60 \"Introduction to tornado\" \u63d0\u95ee", 
      "id": "https://www.v2ex.com/t/164660"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/jecvay", 
        "name": "jecvay", 
        "avatar": "https://cdn.v2ex.com/avatar/5d88/04b8/75586_large.png?m=1668072609"
      }, 
      "url": "https://www.v2ex.com/t/163815", 
      "date_modified": "2015-01-20T05:41:54+00:00", 
      "content_html": "<p>\u6211\u6ca1\u6709\u5f00\u53d1\u7f51\u7ad9\u7684\u7ecf\u9a8c, \u53ea\u662f\u770b\u8fc7\u4e86Python\u548cTornado\u90a3\u672c100\u591a\u9875\u7684\u5165\u95e8\u4e66. <br>\n\u73b0\u5728\u6709\u4e2a\u9879\u76ee\u662f\u505a\u4e2a\u7ba1\u7406\u7cfb\u7edf\u7f51\u7ad9, \u6253\u7b97\u7528 <strong>Mongodb</strong> \u6570\u636e\u5e93. <br>\n\u800c\u4e14\u6211\u5bf9<strong>\u5f02\u6b65</strong>\u4ec0\u4e48\u7684\u6ca1\u6709\u4efb\u4f55\u7ecf\u9a8c, </p>\n\n<p>\u8bf7\u95ee\u6709\u4ec0\u4e48\u8981\u6ce8\u610f\u7684?</p>\n", 
      "date_published": "2015-01-20T05:35:00+00:00", 
      "title": "\u7528 Tornado + Mongodb \u5f00\u53d1\u8981\u6ce8\u610f\u4ec0\u4e48?", 
      "id": "https://www.v2ex.com/t/163815"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/Livid", 
        "name": "Livid", 
        "avatar": "https://cdn.v2ex.com/avatar/c4ca/4238/1_large.png?m=1775624785"
      }, 
      "url": "https://www.v2ex.com/t/163238", 
      "title": "\u7528 Tornado \u505a\u7684\u7f51\u7ad9\uff0c\u5927\u5bb6\u5728\u5199\u6d4b\u8bd5\u7684\u65f6\u5019\uff0c\u4e00\u822c\u90fd\u662f\u600e\u4e48\u505a\u7684\u5462\uff1f", 
      "id": "https://www.v2ex.com/t/163238", 
      "date_published": "2015-01-18T09:08:41+00:00", 
      "content_html": ""
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/mqingyn616", 
        "name": "mqingyn616", 
        "avatar": "https://cdn.v2ex.com/avatar/7ec9/a2d2/91953_large.png?m=1421303756"
      }, 
      "url": "https://www.v2ex.com/t/162401", 
      "title": "\u5206\u4eab\u672c\u4eba\u57fa\u4e8e tornado \u5f00\u53d1\u7684\u5e94\u7528\u5c42\u6846\u67b6", 
      "id": "https://www.v2ex.com/t/162401", 
      "date_published": "2015-01-15T06:31:38+00:00", 
      "content_html": "<p><a target=\"_blank\" rel=\"nofollow\" href=\"https://github.com/mqingyn/torngas\">https://github.com/mqingyn/torngas</a></p>\n\n<p>Torngas \u662f\u57fa\u4e8eTornado\u7684\u5e94\u7528\u5f00\u53d1\u6846\u67b6\uff0ctornado\u662f\u4e00\u4e2a\u5f02\u6b65\u975e\u963b\u585e\u7684web\u6846\u67b6\uff0c\u4f46\u662f\u7531\u4e8e\u5176\u5c0f\u5de7\u7075\u6d3b\uff0c\u5e76\u6ca1\u6709\u4e00\u4e2a\u7edf\u4e00\uff0c\u901a\u7528\u7684 \u5e94\u7528\u5c42\u6846\u67b6\u89e3\u51b3\u65b9\u6848\u3002Torngas \u5927\u91cf\u53c2\u8003\u548c\u501f\u9274\u4e86Django\u7684\u8bbe\u8ba1\u6a21\u5f0f\uff0c\u5f62\u6210\u4e00\u5957\u57fa\u4e8etornado\u7684Django like\u5e94\u7528\u5c42\u5f00\u53d1\u6846\u67b6\u3002<br>\n\u8fd9\u4e2a\u6846\u67b6\u5df2\u7ecf\u5e94\u7528\u5728\u5343\u4e07\u7ea7PV\u7684\u9879\u76ee\u91cc\uff0c\u73b0\u5728\u5f00\u6e90\u51fa\u6765\uff0c\u5e0c\u671b\u5bf9\u5927\u5bb6\u6709\u7528\u3002^ _^</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/jecvay", 
        "name": "jecvay", 
        "avatar": "https://cdn.v2ex.com/avatar/5d88/04b8/75586_large.png?m=1668072609"
      }, 
      "url": "https://www.v2ex.com/t/160351", 
      "title": "Nginx \u591a\u7aef\u53e3\u8fd0\u884c Tornado \u5982\u4f55\u83b7\u53d6\u5f53\u524d\u7aef\u53e3", 
      "id": "https://www.v2ex.com/t/160351", 
      "date_published": "2015-01-08T07:58:39+00:00", 
      "content_html": "<p>\u914d\u7f6e\u4e86 Nginx \u4f1a\u5c06\u8bf7\u6c42\u5206\u7ed9 8000:8003 \u56db\u4e2a\u7aef\u53e3, \u6211\u60f3Tornado\u5efa\u4e00\u4e2a\u9875\u9762, \u8bbf\u95ee\u8fd9\u4e2a\u9875\u9762\u7684\u65f6\u5019\u6d4f\u89c8\u5668\u4e0a\u80fd\u663e\u793a\u51fa\u8fd9\u4e2a\u9875\u9762\u7684\u8bf7\u6c42\u7531\u54ea\u4e00\u4e2a\u7aef\u53e3\u83b7\u53d6\u4e86, \u5982\u4f55\u80fd\u5b9e\u73b0\u8fd9\u4e2a\u529f\u80fd? </p>\n\n<p>RequestHandler \u8c8c\u4f3c\u6ca1\u6709\u4f20\u8fdb\u6765\u7aef\u53e3\u53f7?</p>\n"
    }, 
    {
      "author": {
        "url": "https://www.v2ex.com/member/blueandhack", 
        "name": "blueandhack", 
        "avatar": "https://cdn.v2ex.com/avatar/c03d/ada7/34443_large.png?m=1707800861"
      }, 
      "url": "https://www.v2ex.com/t/156122", 
      "title": "Tornado \u6846\u67b6\u5982\u4f55\u5199 MVC \u6a21\u5f0f\uff1f", 
      "id": "https://www.v2ex.com/t/156122", 
      "date_published": "2014-12-23T13:06:49+00:00", 
      "content_html": "\u4e4b\u524d\u5199\u8fc7Nodejs\uff0c\u4e0d\u77e5\u9053Tornado\u5982\u4f55\u6765\u5199\uff0c\u6709\u53ef\u4ee5\u53c2\u8003\u7684\u4f8b\u5b50\u5417\uff1f<br />\u4e4b\u524d\u641c\u8fc7\uff0c\u6ca1\u627e\u5230\u4e00\u4e2a\u5b8c\u6574\u9879\u76ee\uff0c\u5c31\u63a8\u8350\u3002"
    }
  ]
}