An asynchronous session backend with mongodb for tornado
Project description
- Info:
Torsession is an asynchronous session backend with Mongodb for Tornado
Installation
$ pip install git+https://github.com/mongodb/motor.git
$ pip install torsession
Dependencies
tornado 3+
motor 0.1+
Example
Create a new session after login:
yield session.new_session()
Clear current session when logout:
yield session.delete_session()
Get a value:
yield session.get(key)
Set a value:
yield session.set(key, value)
Delete a value:
yield session.delete(key)
Refresh session id:
yield session.refresh_session()
Get session id:
session.session_id
Set session id:
session.session_id = new_session_id
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
torsession-0.1.3.tar.gz
(3.1 kB
view hashes)