Skip to navigation
Fast asynchronous couchdb document update with tornado-couchdb
16.02.16
from tornado import ioloop, gen import couch class My_class(): def __init__(self): pass @gen.coroutine def update(self): db = couch.AsyncCouch('MYDB_NAME',MYDB_URL) doc = yield db.get_doc('MYID') r = yield cdb.save_doc(doc) print(r) @gen.coroutine def xstart(): c = My_class() yield c.update() if __name__ == "__main__": main_loop = ioloop.IOLoop.instance() main_loop.run_sync(xstart)
https://github.com/nephics/tornado-couchdb
Reply
Anonymous
Information Epoch 1732600563
Think hierarchically.
Home
Notebook
Contact us