问题描述
expressjs/nodejs是否对数据库会话有支持(通过模块?)?我来自PHP/Codeigniter的世界,我很喜欢将会话数据存储在MySQL数据库表中的功能.
Nodejs Web应用程序是否使用此方法?
推荐答案
是.
redis
mysql
-
https://github.com/mren/mren/connect-session-mysql断开链接 -
https://github.com/carnegielearning/carnegielearning/connect-mysql-session >旧的,不支持的 - https://github.com/chill117/chill117/chill117/express-mysql-session
PostgreSQL
mongodb
- https://github.com/kcbanner/connect-mongo
- https://github.com/bartt/connect-session-mongo
- https://github.com/donpark/donpark/session-mongoose
- https://github.com/masylum/masylum/connect-mongodb
memcached
couchdb
riak
sqlite
- https://github.com/tnantoka/connect-sqlite
- https://github.com/pkrumins/pkrumins/supermarket-cart-cart
基于文件的
京都卡比尼特
azure
nstore
节点dirty
voc(?)
azure
nstore
节点dirty
voc(?)
实现自己的功能非常简单,请参见此处的文档.
问题描述
Does expressjs/nodejs have support (via a module?) for database sessions? I come from the world of PHP/CodeIgniter and I've enjoyed the features of storing session data in a mysql database table.
Is this approach used with nodejs web apps?
推荐答案
Yes.
Redis
MySQL
https://github.com/mren/connect-session-mysqlBroken Linkhttps://github.com/CarnegieLearning/connect-mysql-sessionOld, Unsupported- https://github.com/chill117/express-mysql-session
PostgreSQL
MongoDB
- https://github.com/kcbanner/connect-mongo
- https://github.com/bartt/connect-session-mongo
- https://github.com/donpark/session-mongoose
- https://github.com/masylum/connect-mongodb
Memcached
CouchDB
Riak
SQLite
File-based
Kyoto-cabinet
Azure
nStore
node-dirty
VOC (?)
It's quite simple to implement your own, see documentation here.