Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

mayflaver/AsyncTorndb

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
17 Commits
 
 
 
 
 
 

Repository files navigation

AsyncTorndb(inactive)

Async mysql client for tornado base on PyMySQL.

Documentation

AsyncTorndb behavior is almost like torndb behavior, but async. Refer to torndb and have a try.

Requirements

Demo

Here is a simple "Hello, world" example web app for AsyncTorndb::

import tornado.ioloop
import tornado.web
import tornado.gen
import asynctorndb

class MainHandler(tornado.web.RequestHandler):
    @tornado.gen.coroutine
    def get(self):
        conn = asynctorndb.Connect(user='demo', passwd='demo', database='demo')
        yield conn.connect()
        result = yield conn.query('select * from user')
        # do something with result
        self.write("Hello, world")

application = tornado.web.Application([
    (r"/", MainHandler),
])

if __name__ == "__main__":
    application.listen(8888)
    tornado.ioloop.IOLoop.instance().start()

License

AsyncTorndb is released under the MIT License. See LICENSE for more information.

About

async mysql client for tornado

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.