steverobbins / Magento-Redismanager

Superuser control for Redis in Magento
137 stars 31 forks source link

Compatibility with Cm_RedisSession & Cm_Cache_Backend_Redis #16

Closed sasoriza closed 8 years ago

sasoriza commented 9 years ago

I am using your extension alongside these both: https://github.com/colinmollenhour/Cm_RedisSession https://github.com/colinmollenhour/Cm_Cache_Backend_Redis and noticed the following behavior:

If I only include the edits for Cm_RedisSession in my local.xml, your Redis Manager will list the session database as being in use. As soon as I also include the Cm_Cache_Backend_Redis edits, both databases will be listed in your Redis Manager but the session db will remain empty.

Is this a problem with your Redis Manager or am I doing something wrong? This is the related code in my local.xml I am trying:

<!-- Cm_Cache_Backend_Redis -->
<cache>
  <backend>Cm_Cache_Backend_Redis</backend>
  <backend_options>
    <server>127.0.0.1</server>
    <port>6379</port>
    <persistent></persistent>
    <database>1</database>
    <password></password>
    <force_standalone>1</force_standalone>
    <connect_retries>1</connect_retries>
    <read_timeout>10</read_timeout>
    <automatic_cleaning_factor>0</automatic_cleaning_factor>
    <compress_data>1</compress_data>
    <compress_tags>1</compress_tags>
    <compress_threshold>20480</compress_threshold>
    <compression_lib>gzip</compression_lib>
    <use_lua>0</use_lua>
  </backend_options>
</cache>
<!-- Cm_RedisSession -->  
<session_save>db</session_save>
<redis_session>
    <host>127.0.0.1</host>
    <port>6379</port>
    <password></password>
    <timeout>2.5</timeout>
    <persistent></persistent>
    <db>2</db>
    <compression_threshold>2048</compression_threshold>
    <compression_lib>gzip</compression_lib>
    <log_level>4</log_level>
    <max_concurrency>6</max_concurrency>
    <break_after_frontend>5</break_after_frontend>
    <break_after_adminhtml>30</break_after_adminhtml>
    <first_lifetime>600</first_lifetime>
    <bot_first_lifetime>60</bot_first_lifetime>
    <bot_lifetime>7200</bot_lifetime>
    <disable_locking>0</disable_locking>
    <min_lifetime>60</min_lifetime>
    <max_lifetime>2592000</max_lifetime>
</redis_session>

Can you reproduce this issue if you use all three extensions?

steverobbins commented 9 years ago

Have you enabled Cm_RedisSession in app/etc/modules/Cm_RedisSession.xml?

sasoriza commented 8 years ago

I completely removed both Cm_RedisSession and Cm_Cache_Backend_Redis and reinstalled whilst updating to 1.9.2.2 and now it's seems to be working. I am not sure what I did wrong the first time, I know it was working for some time and suddenly I noticed my core_session table growing larger and larger. All fixed now though...