phpnode / YiiRedis

A set of wrappers for different data types in redis
141 stars 56 forks source link

Config-level connection for session (and cache?) #17

Open 0x0ece opened 10 years ago

0x0ece commented 10 years ago

Hi,

I'd like to separate data in different databases, in particular sessions from data, say respectively into database 1 and 2.

I noticed you can instantiate any RedisEntity by specifying a connection, so in principle I can do that. However, I'd find more usable/less error prone to setup the default connection for data, and configure session to use another connection.

A proposal follows, please let me know if you'd like a pull request. E.

otaviofcs commented 10 years ago

Hi ecesena,

+1

I can't agree more. And should be different from CRedisCache also. If you specify the change proposal we can develop it together.

Best,

Otávio

vgoodvin commented 10 years ago

+1. The same problem is in the ARedisStatePersister.php. That would be great, if you can provide pull request.