connect-redis is very slow. I can't optimize it too much

here is my test

none-session: RPS: 5k

connect-redis: RPS: 2.1k

fake redis session: `function(req, res, next) { redisClient.get('foo',
next) }`
RPS: 3.7k

connect mem session is deprecated, and it also slow
RPS: 3.2k

I think connect-session is a little complex after I read the code.

For a production environment, we can use a hash load balance, same user
will always goes to same process, so we can use in process cache as
session, and this cache module will not only use for session, it could also
help on real time service like chat and game.

Here is my proposal for in process cache.

1. TTL or LRU
2. store as primitive type not string.
3. use a native module, can use more memory than v8 limitation.

I hope this could be apart of node.js.

I don't know are there any existing modules like this?

-- 
Best regards,

桂林 (Gui Lin)

guileen@twitter
桂林-V@weibo <http://weibo.com/guileen>
guileen@github <https://github.com/guileen>

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to