visionmedia/connect-redis — pull request #54 by louischatriot (2012-08-27 11:48:54+00:00)
Title: RedisStore can have its users (e.g connect-session) handle connection to Redis problems

Hello TJ,

As discussed [here](https://github.com/visionmedia/connect-redis/pull/50), I implemented a "safe mode" for the RedisStore. If enabled through the "safeMode" option, the 'error' event emitted by the redis driver is caught, preventing a node crash, and a 'connectionError' is emitted instead, which the user can use to know what state the RedisStore is in and act accordingly. In the case of Connect's session middleware, if the RedisStore is not ready, we simply pass the request to the next middleware, thus acting as if there was no session at all.

Related PR on connect :

Louis