Nodejs 连接 mysql时报错 Error: Cannot enqueue Query after fatal error

解决办法,参考:https://github.com/chill117/express-mysql-session/issues/18

 

我们只需在实例化SessionStore的时候,配置useConnectionPooling: true。比如:

var sessionStore = new SessionStore({
    host: 'localhost',
    port: 3306,
    user: 'root',
    password: 'root',
    database: 'session',
    useConnectionPooling: true
});

 

posted on 2015-09-25 19:26  叫我钱了个浅  阅读(12182)  评论(0编辑  收藏  举报

导航