Redis-based session handler for Magento with optimistic locking

Overview

Cm_RedisSession

A Redis-based session handler for Magento with optimistic locking.

Features:

  • Falls back to mysql handler if it can't connect to Redis. Mysql handler falls back to file handler.
  • When a session's data size exceeds the compression threshold the session data will be compressed.
  • Compression libraries supported are 'gzip', 'lzf', 'lz4', and 'snappy'. -- Gzip is the slowest but offers the best compression ratios. -- Lzf can be installed easily via PECL. -- Lz4 is supported by HHVM.
  • Compression can be enabled, disabled, or reconfigured on the fly with no loss of session data.
  • Expiration is handled by Redis; no garbage collection needed.
  • Logs when sessions are not written due to not having or losing their lock.
  • Limits the number of concurrent lock requests before a 503 error is returned.
  • Detects inactive waiting processes to prevent false-positives in concurrency throttling.
  • Detects crashed processes to prevent session deadlocks (Linux only).
  • Gives shorter session lifetimes to bots and crawlers to reduce wasted resources.
  • Locking can be disabled entirely using config or define('CM_REDISSESSION_LOCKING_ENABLED', FALSE); or by setting $this->setFlag('', Cm_RedisSession_Model_Session::FLAG_READ_ONLY, 1) flag in controller predispatch.
  • Requires PHP >= 5.3. Yes, this is a feature. You're welcome. ;)

Locking Algorithm Properties:

  • Only one process may get a write lock on a session.
  • A process may lose it's lock if another process breaks it, in which case the session will not be written.
  • The lock may be broken after BREAK_AFTER seconds and the process that gets the lock is indeterminate.
  • Only MAX_CONCURRENCY processes may be waiting for a lock for the same session or else a 503 error is returned.

Session Cookie Management:

The Cookie Lifetime is configured here (Magento default): System > Configuration > Web > Session Cookie Management > Cookie Lifetime. You can override the default session lifetime settings of this module by setting the <max_lifetime> and <min_lifetime> handle if you need to adjust your session lifetime settings. Be aware that if the <max_lifetime> setting is below your Cookie Lifetime, the <max_lifetime>-setting will be taken.

Installation

This extension can be installed with either Composer or modman.

The Magento Compiler feature is currently not supported.

Modman Installation

  1. Install module using modman:

     modman clone https://github.com/colinmollenhour/Cm_RedisSession
    
  2. Configure via app/etc/local.xml adding a global/redis_session section with the appropriate configuration if needed. See the "Configuration Example" below.

  3. Refresh the config cache to allow the module to be installed by Magento.

  4. Test the configuration by running the migrateSessions.php script in --test mode.

     sudo php .modman/Cm_RedisSession/migrateSessions.php --test
    
  5. Change the global/session_save configuration to "db" in app/etc/local.xml. The "db" value is the MySQL handler, but Cm_RedisSession overrides it to avoid modifying core files.

  6. Migrate the old sessions to Redis. See the "Migration" section below for details. The migration script will clear the config cache after migration is complete to activate the config change made in step 5.

Configuration Example

<config>
    <global>
        ...
        <session_save>db</session_save>
        <redis_session>                       <!-- All options seen here are the defaults -->
            <host>127.0.0.1</host>            <!-- Specify an absolute path if using a unix socket -->
            <port>6379</port>
            <password></password>             <!-- Specify if your Redis server requires authentication -->
            <timeout>2.5</timeout>            <!-- This is the Redis connection timeout, not the locking timeout -->
            <persistent></persistent>         <!-- Specify unique string to enable persistent connections. E.g.: sess-db0; bugs with phpredis and php-fpm are known: https://github.com/nicolasff/phpredis/issues/70 -->
            <db>0</db>                        <!-- Redis database number; protection from accidental loss is improved by using a unique DB number for sessions -->
            <compression_threshold>2048</compression_threshold>  <!-- Known bug with strings over 64k: https://github.com/colinmollenhour/Cm_Cache_Backend_Redis/issues/18 -->
            <compression_lib>gzip</compression_lib>              <!-- gzip, lzf, lz4, snappy or none to disable compression -->
            <log_level>1</log_level>               <!-- 0 (emergency: system is unusable), 4 (warning; additional information, recommended), 5 (notice: normal but significant condition), 6 (info: informational messages), 7 (debug: the most information for development/testing) -->
            <max_concurrency>6</max_concurrency>                 <!-- maximum number of processes that can wait for a lock on one session; for large production clusters, set this to at least 10% of the number of PHP processes -->
            <break_after_frontend>5</break_after_frontend>       <!-- seconds to wait for a session lock in the frontend; not as critical as admin -->
            <fail_after>10</fail_after>                          <!-- seconds after which we bail from attempting to obtain lock (in addition to break after time) -->
            <break_after_adminhtml>30</break_after_adminhtml>
            <first_lifetime>600</first_lifetime>                 <!-- Lifetime of session for non-bots on the first write. 0 to disable -->
            <bot_first_lifetime>60</bot_first_lifetime>          <!-- Lifetime of session for bots on the first write. 0 to disable -->
            <bot_lifetime>7200</bot_lifetime>                    <!-- Lifetime of session for bots on subsequent writes. 0 to disable -->
            <disable_locking>0</disable_locking>                 <!-- Disable session locking entirely. -->
            <min_lifetime>60</min_lifetime>                      <!-- Set the minimum session lifetime -->
            <max_lifetime>2592000</max_lifetime>                 <!-- Set the maximum session lifetime -->
            <log_exceptions>0</log_exceptions>                   <!-- Log connection failure and concurrent connection exceptions in exception.log. -->
        </redis_session>
        ...
    </global>
    ...
</config>

Migration

A script is included to make session migration from files storage to Redis with minimal downtime very easy. Use a shell script like this for step 6 of the "Installation" section.

cd /var/www              # Magento installation root
touch maintenance.flag   # Enter maintenance mode
sleep 2                  # Allow any running processes to complete
# This will copy sessions into redis and clear the config cache so local.xml changes will take effect
sudo php .modman/Cm_RedisSession/migrateSessions.php -y
rm maintenance.flag      # All done, exit maintenance mode

Depending on your server setup this may require some changes. Old sessions are not deleted so you can run it again if there are problems. The migrateSessions.php script has a --test mode which you definitely should use before the final migration. Also, the --test mode can be used to compare compression performance and ratios. Last but not least, the --test mode will tell you roughly how much space your compressed sessions will consume so you know roughly how to configure maxmemory if needed. All sessions have an expiration so volatile-lru or allkeys-lru are both good maxmemory-policy settings.

Compression

Session data compresses very well so using compression is a great way to increase your capacity without dedicating a ton of RAM to Redis and reducing network utilization. The default compression threshold is 2048 bytes so any session data equal to or larger than this size will be compressed with the chosen compression_lib which is gzip by default. Compression can be disabled by setting the compression_lib to none. However, both lzf and snappy offer much faster compression with comparable compression ratios so I definitely recommend using one of these if you have root. lzf is easy to install via pecl:

sudo pecl install lzf

NOTE: If using suhosin with session data encryption enabled (default is suhosin.session.encrypt=on), two things:

  1. You will probably get very poor compression ratios.
  2. Lzf fails to compress the encrypted data in my experience. No idea why...

If any compression lib fails to compress the session data an error will be logged in system.log and the session will still be saved without compression. If you have suhosin.session.encrypt=on I would either recommend disabling it (unless you are on a shared host since Magento does it's own session validation already) or disable compression or at least don't use lzf with encryption enabled.

Bot Detection

Bots and crawlers typically do not use cookies which means you may be storing thousands of sessions that serve no purpose. Even worse, an attacker could use your limited session storage against you by flooding your backend, thereby causing your legitimate sessions to get evicted. However, you don't want to misidentify a user as a bot and kill their session unintentionally. This module uses both a regex as well as a counter on the number of writes against the session to determine the session lifetime.

Using with Cm_Cache_Backend_Redis

Using Cm_RedisSession alongside Cm_Cache_Backend_Redis should be no problem at all. The main thing to keep in mind is that if both the cache and the sessions are using the same database, flushing the cache backend would also flush the sessions! So, don't use the same 'db' number for both if running only one instance of Redis. However, using a separate Redis instance for each is recommended to make sure that one or the other can't run wild consuming space and cause evictions for the other. For example, configure two instances each with 100M maxmemory rather than one instance with 200M maxmemory.

License

@copyright  Copyright (c) 2013 Colin Mollenhour (http://colin.mollenhour.com)
This project is licensed under the "New BSD" license (see source).
Comments
  • Redis::expire() expects parameter 2 to be integer, string given

    Redis::expire() expects parameter 2 to be integer, string given

    I upgraded to last version recently. Seeing this in logging. Using magento github lts 1937

    Redis::expire() expects parameter 2 to be integer, string given in /app/code/local/Credis/Client.php on line 1132

    opened by seansan 38
  • performance problems...

    performance problems...

    I have a multi-vps Magento setup which is currently sharing a dedicated redis data store across 6 workers - each dedicated solely to processing php.

    After recently being asked to install New Relic to investigate performance problems, it is reporting that one of the main culprits is the redis session stuff, with an example trace showing 48% in Credis_Client::__call, and 40% in Cm_RedisSession_Model_Session::read. The big worry was that the complete /catalog/category/view 'transaction' took just under 80s to complete!

    Now it looks like the newrelic.so PHP plugin is based on xdebug, which is known to mess with performance anyway, so I am taking this with a pinch of salt.

    When I run perf tests via the cli from the same server, all runs fine. The redis server is not overloaded, although network traffic may be in excess of 40Mbit/s. I have updated to the latest RedisSession plugin. I have updated redis to 2.6.14, and it is now not saving session details to disk. I have updated phpredis to current

    My current config is...

        <session_save><![CDATA[db]]></session_save>
        <redis_session>                      
            <host>192.168.132.86</host>
            <port>6379</port>
            <timeout>5.0</timeout>            
            <persistent></persistent>        
            <db>0</db>
            <compression_threshold>0</compression_threshold>  
            <compression_lib>gzip</compression_lib>              
            <log_broken_locks>0</log_broken_locks>              
            <max_concurrency>8</max_concurrency>
            <break_after_frontend>5</break_after_frontend>     
            <break_after_adminhtml>30</break_after_adminhtml>
            <bot_lifetime>7200</bot_lifetime>                   
        </redis_session>
    

    I upped the break_after_frontend to 5s to see if that would help - maybe there was a timeout at 2.5 and the delay was caused by updating sessions to the database?? -and have tried both persistent and non-persistent connections.

    monitoring of the redis process and underlying servers themselves shows no problems - responding to change in loads, and nowhere near cpu/mem capacity.

    If you have any ideas, please let me know!

    Cheers,

    Steve

    EDIT: I currently seem to have c. 50,000 sessions stored in redis, but only have an access rate of c. 4/s. Is there a simple way I can be more agressive in clearing theold session details out?

    opened by sholdowa 26
  • frequent read error on connection in backend only

    frequent read error on connection in backend only

    We are having repeated problems with the admin backend in Magento, but not any frequent problems on the front end. The front end is handled on two separate nodes, and a third runs the backend, all sharing common Redis caches (separate instances for Sessions, Magento Cache, and Full Page Cache). The Redis instances are on a 4th server.

    a:5:{i:0;s:71:"read error on connection";i:1;s:2311:"#0 /var/www/vhosts/www.example.com/.modman/Cm_RedisSession/code/Model/Session.php(380): Credis_Client->__call('exec', Array)
    #1 /var/www/vhosts/www.example.com/.modman/Cm_RedisSession/code/Model/Session.php(380): Credis_Client->exec()
    #2 [internal function]: Cm_RedisSession_Model_Session->read('cm0uenj0pdj4im6...')
    #3 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php(125): session_start()
    #4 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php(168): Mage_Core_Model_Session_Abstract_Varien->start('adminhtml')
    #5 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Model/Session/Abstract.php(84): Mage_Core_Model_Session_Abstract_Varien->init('core', 'adminhtml')
    #6 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Model/Session.php(42): Mage_Core_Model_Session_Abstract->init('core', 'adminhtml')
    #7 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Model/Config.php(1348): Mage_Core_Model_Session->__construct(Array)
    #8 /var/www/vhosts/www.example.com/app/Mage.php(463): Mage_Core_Model_Config->getModelInstance('core/session', Array)
    #9 /var/www/vhosts/www.example.com/app/Mage.php(477): Mage::getModel('core/session', Array)
    #10 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Controller/Varien/Action.php(493): Mage::getSingleton('core/session', Array)
    #11 /var/www/vhosts/www.example.com/app/code/core/Mage/Adminhtml/Controller/Action.php(160): Mage_Core_Controller_Varien_Action->preDispatch()
    #12 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Controller/Varien/Action.php(407): Mage_Adminhtml_Controller_Action->preDispatch()
    #13 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('start')
    #14 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
    #15 /var/www/vhosts/www.example.com/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
    #16 /var/www/vhosts/www.example.com/app/Mage.php(684): Mage_Core_Model_App->run(Array)
    #17 /var/www/vhosts/www.example.com/index.php(98): Mage::run('', 'store')
    #18 {main}";s:3:"url";s:99:"/index.php/admin/sales_order_create/start/customer_id/3115/key/99f5680349b18f208dc386bcceaec7a6/";s:11:"script_name";s:10:"/index.php";s:4:"skin";s:5:"admin";}
    

    There isn't a large number of admin requests occurring (typically only one or two people using it) and the other nodes appear to communicate to Redis just fine. They're all Rackspace cloud performance 8GB servers in the same DC.

    Since this only happens in the backend, I'm not sure if it's just a backend triggered issue, or if it's the server, but I've tried monitoring connectivity to redis from that server and it never fails (and the cache / full page cache never error, just sessions).

    Any suggestions on what to look for / instrument to investigate this? I tried adding a call to a shell command to get the number of active / time_wait / etc Redis connections when the error occurs, but there's never more than a couple in total on that server, so I'm pretty sure its not any kind of socket/descriptor starvation.

    edit: replaced stacktrace with correct one

    opened by jonathanvaughn 18
  • Unable to login to admin using PHP 7.0.0 and CM Redis Session

    Unable to login to admin using PHP 7.0.0 and CM Redis Session

    This is on my Mac, PHP 7.0.0 final and PHP 7.0 branch of redis.

    2015-12-04T10:18:52+00:00 ERR (admin): /index.php/admin REQUEST: POST|{"form_key":"JmaxqtYwA8DMMSVm","login":{"username":"ccarnell","password":"*****"},"dummy":""} TIME: 0.144938s ADDRESS: 127.0.0.1 USER AGENT: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:42.0) Gecko/20100101 Firefox/42.0 FILE: mysite/app/code/core/Mage/Core/functions.php:247 Recoverable Error: session_regenerate_id(): Failed to create(read) session ID: user (path: ) in /Users/ccarnell/Sites/mysite/app/code/local/Mage/Core/Model/Session/Abstract/Varien.php on line 493

    opened by craigcarnell 17
  • Customers losing session

    Customers losing session

    Hi guys

    Occasionally some customers are losing the session. But my local test works great and many customers can buy without problems.

    So I don't know how to investigate the problem. Any tip? Anyone with same problem?

    p.s. Some time ago I've installed that Plumrocket AMP extension and it was great for performance and SEO. My tests with the extension are Ok too. Could it be related with?

    opened by rafaelpatro 16
  • Implement read-only (lockless) session

    Implement read-only (lockless) session

    Since I am struggling with delayed AJAX requests due to session locking, I am wondering if it would make sense to implement an option (set through a special parameter using define() maybe?) that would change the session to read-only mode (this would mean disable locking on read and do nothing on write). This way, in cases when we are sure that the session data will not be changed by the current request, there would be a considerable response speed increase.

    I think it would be a nice feature; I can make a PR if you think it's worth implementing.

    opened by nemphys 11
  • 3.0.1 can not load the session model using composer

    3.0.1 can not load the session model using composer

    When I try to use the class:

    <?php
    
    include_once 'vendor/autoload.php';
    
    //$c = new \Cm\RedisSession\Model\Session();
    $c = new Cm_RedisSession_Model_Session();
    

    In both cases I'm getting either

    PHP Fatal error:  Uncaught Error: Class 'Cm\RedisSession\Model\Session' not found in /magento/1.php:5
    Stack trace:
    #0 {main}
      thrown in /magento/1.php on line 5
    

    or

    PHP Fatal error:  Uncaught Error: Class 'Cm_RedisSession_Model_Session' not found in /magento/1.php:6
    Stack trace:
    #0 {main}
      thrown in /magento/1.php on line 6
    

    Composer version 2.2.17, PHP 7.1

    opened by speller 10
  • Session Lost PHP 7.0 + Suhosin

    Session Lost PHP 7.0 + Suhosin

    Hello,

    I'm using Magento 1.9.x with Nginx/PHP-FPM 7.0, if i enable suhosin module (more specifically "suhosin.session.encrypt" option) my backend session lost randomically, if i press f5 multiple times the session down and i need login again.

    There are some incompatibility with module and suhosin?

    Thank you!

    opened by caiohasouza 10
  • mod_fcgid: stderr: PHP Fatal error:

    mod_fcgid: stderr: PHP Fatal error:

    I try to install the Cm_RedisSession Modul manually but I got the following error:

    mod_fcgid: stderr: PHP Fatal error:  
    Class Cm_RedisSession_Model_Session_Config contains 4 abstract methods and must therefore be declared abstract or implement the remaining methods 
    (Cm\\RedisSession\\Handler\\ConfigInterface::getSentinelServers, Cm\\RedisSession\\Handler\\ConfigInterface::getSentinelMaster, Cm\\RedisSession\\Handler\\ConfigInterface::getSentinelVerifyMaster, ...) 
    in /var/www/share/shop/htdocs/app/code/local/Cm/RedisSession/Model/Session/Config.php on line 197
    

    My Folder Structure:

    app/code/local --Cm/RedisSession ----Cm_RedisSession Files ----lib/src/Cm/RedisSession ------php-redis-session-abstract FIles --Credis ----credis Files

    opened by bbtimx 10
  • Feature/instrumentation

    Feature/instrumentation

    I’m hoping this can be a collaborative effort between @colinmollenhour, @jonpday, @aedmonds and myself (Cc: @kyleterry for visibility). Could we use this pull request to review the proposed change and make improvements?

    Changes

    • Refactored log_broken_locks into a log_level with standard levels (RFC-3164); deprecated log_broken_locks
    • Adjusted log messages for clarity and changed level of existing log messages based on my understanding of severity
    • Added debug loggers to aid developers in understanding the internals
    • Added timing and compression instrumentation (at debug level) to aid developers

    Testing

    • I haven’t yet tested any of this, and I’m aware that’s in bad form (firing up a VM now…)
    opened by parhamr 10
  • Path issue to ConfigInterface.php when using symlink Composer deployment strategy

    Path issue to ConfigInterface.php when using symlink Composer deployment strategy

    When this module is installed via Composer with the magento-hackathon/magento-composer-installer, the following error occurs:

    PHP Fatal error:  require_once(): Failed opening required '/var/www/myproject/branches/master/vendor/colinmollenhour/magento-redis-session/code/Model/../lib/src/Cm/RedisSession/Handler/ConfigInterface.php' (include_path='/var/www/myproject/branches/master/vendor/magento/zendframework1/library:/var/www/myproject/branches/master/app/code/local:/var/www/myproject/branches/master/app/code/community:/var/www/myproject/branches/master/app/code/core:/var/www/myproject/branches/master/lib:.:/usr/share/pear:/usr/share/php') in /var/www/myproject/branches/master/vendor/colinmollenhour/magento-redis-session/code/Model/Session.php on line 32
    

    I am using this as a temporary fix in my composer.json:

        "scripts": {
            "post-install-cmd": [
                "cd vendor/colinmollenhour/magento-redis-session/code/lib && ln -s ../../../php-redis-session-abstract/src"
            ]
        }
    

    There is a missing connection on the lib/src directory needing to be pointed to the php-redis-session-abstract/src directory. Another fix for this I believe would be to not call the require at all in the php and let the autoloader find it.

    opened by kirkmadera 9
  • Native Magento Redis Session extension

    Native Magento Redis Session extension

    Hello,

    In the past, I had installed the extension Cm_RedisSession on Magento 1.7.0.2. The relevant extension had been installed under the directory /app/code/local/Cm/RedisSession. Afterwards, I upgraded to Magento 1.9.4.5 which has native support for Redis sessions. So, I ended up with having code under both the following directories:

    /app/code/local/Cm/RedisSession /app/code/community/Cm/RedisSession

    The file /app/etc/modules/Cm_RedisSession.xml seems to be that of Magento 1.9.4.5 which has codePool=community, and not the one of the extension Cm_RedisSession I got from github which had codePool=local. However, after conducting some checks I got the impression that the Cm_RedisSession extension actually used by my Magento installation is the initial one installed under /app/code/local/Cm, and not the native one installed under /app/code/community/Cm.

    So, I have 3 questions:

    1. How can I make the native one be used by Magento installation?
    2. Which of the above extensions System > Configuration > Advanced > Cm_RedisSession=Enable corresponds to?
    3. I know that the Cm_RedisSession I got from github does not support Compiler. Can I enable Magento compiler with the native Cm_RedisSession extension of Magento 1.9.4.5?
    opened by dandrikop 0
  • Session IDs are plain text in redis (missing hash)

    Session IDs are plain text in redis (missing hash)

    When attacker gains partial access to server, it is really easy to steal all session ids with simple command:

    redis-cli keys sess_*
    

    From my view, it is wrong that the session_id is used as plain text as redis key. I would hash+salt the session_id for creating the redis key. If this would be applied, the attack described above would not be possible, because the only thing that you would get, would be hashes that cannot be used as cookie in browser. It protects the sessions even against on-purpose-privileged people, like server admins.

    With the filesystem sessions, you can protect against such attack with setting file owner to root and disallow the webserver user to list the files inside the sessions directory (chmod a-x sessions_dir). Switching to redis session is step down from security view as the session_ids are visible.

    opened by midlan 1
  • missing ConfigInterface

    missing ConfigInterface

    Class Cm_RedisSession_Model_Session_Config implements \Cm\RedisSession\Handler\ConfigInterface. However I can't fin the ConfigInterface.php file. In some places it is also required like:

    require_once __DIR__.'/../lib/src/Cm/RedisSession/Handler/ConfigInterface.php

    Is the file missing, or is the issue on my side?

    Similar story is regarding Cm\RedisSession\Handler\LoggerInterface

    opened by tmotyl 0
  • Make setSaveHandler() only callable once

    Make setSaveHandler() only callable once

    Running EcomDev_PhpUnit with E_ALL on PHP 7.4 (modified version of OpenMage) and my tests are complaining with this error:

    Error: Warning: session_set_save_handler(): Cannot change save handler when headers already sent  in app/code/community/Cm/RedisSession/Model/Session.php on line 51
    

    That's setSaveHandler() being called multiple times. I changed this locally by just putting the call in the constructor. Since it never gets created outside of the getResourceSingleton() calls, this works. Since this repo doesn't have control over those areas, it could instead set a property and check that: private $isSessionSaveHandlerSet = false and then check if it is true/false in the setSaveHandler() method. If it is already set, do nothing.

    opened by joshua-bn 0
  • PHP Warning:  Module 'redis' already loaded in Unknown on line 0

    PHP Warning: Module 'redis' already loaded in Unknown on line 0

    Hello,

    I'm using a Redis instance for Sessions and a separate Redis instance for Cache on Magento 1.9.4.5 with PHP 7.2. Upon every HTTP request, I see the below line at the file error_log:

    PHP Warning: Module 'redis' already loaded in Unknown on line 0

    I don't know which of the two modules Cm_RedisSession or Cm_Cache_Backend_Redis is responsible for that.

    I believe that this warning occurs below ISP has installed Redis module for PHP (see attached screenshot from phpinfo). This line fills up my log file. Is there any way to suppress this warning in the Cm_RedisSession or Cm_Cache_Backend_Redis modules, or the only solution is to remove Redis module from PHP?

    Capture

    opened by dandrikop 1
  • Experiencing delay problems

    Experiencing delay problems

    I was wondering if it's possible to return back from Redis sessions to MySQL without loosing the current sessions set within Redis. There is are migration scripts to migrate to Redis but not vice versa.

    opened by WeszNL 1
Releases(3.0.1)
Owner
Colin Mollenhour
Colin Mollenhour
An alternative Redis session handler for PHP featuring per-session locking and session fixation protection

RedisSessionHandler An alternative Redis session handler featuring session locking and session fixation protection. News phpredis v4.1.0 (released on

Marcel Hernandez 117 Oct 19, 2022
A Redis-backed PHP session handler with optimistic locking

php-redis-session-abstract A Redis-based session handler with optimistic locking. Features: When a session's data size exceeds the compression thresho

Colin Mollenhour 59 Dec 16, 2022
AWS DynamoDB session handler for Magento (experimental!)

Magento Session Handler for AWS DynamoDB Author: Fabrizio Branca TODO: disable automatic gc create cron that does gc how does it keep track of lifetim

AOE 5 Apr 6, 2017
A super simple, clean and pretty error handler that replace the default error handler of PHP. You need only include this file!

php-custom-error-handler A super simple, clean and pretty error handler that replace the default error handler of PHP. You need just include only this

null 6 Nov 7, 2022
This Magento extension provides a Real Full Page Caching for Magento powered by Varnish with support of Session-Based information caching (Cart, Customer Accounts, ...) via ESI includes

This Magento extension provides a Real Full Page Caching (FPC) for Magento powered by Varnish with support of Session-Based information caching (Cart, Customer Accounts, ...) via ESI includes

Hugues Alary 95 Feb 11, 2022
This is a plugin for pocketmine-mp, when locking a player's items helps players not to lose items or throw things around causing server lag.

[] LockedItem| v1.0.0 Player's item lock Features Player's item lock Players aren't afraid of losing items For Devolopers You can access to LockedItem

JeroGamingYT 3 Jan 4, 2022
Personal PHP MySQL query handler based on Eloquent using PDO.

?? Equivoluent Welcome to "Equivoluent" my personal PHP MySQL query handler using PDO. Equivoluent is based on Laravel's Eloquent. The goal of "Equivo

Wob Jelsma 2 Sep 7, 2022
A Zend_Cache backend for Redis with full support for tags (works great with Magento)

Zend_Cache backend using Redis with full support for tags This Zend_Cache backend allows you to use a Redis server as a central cache storage. Tags ar

Colin Mollenhour 389 Jan 4, 2023
The SOLID principles demonstrated in PHP as seen on Elaniin's SOLID Booster Session.

SOLID Principles SOLID is the mnemonic acronym that represents 5 design principles that aim to make software designs more understandable, flexible, an

Vlass Contreras 5 Aug 24, 2022
Web app for kick session in a server 1C use rac/ras

Server requirement OS: Ubuntu 20.04 Usage Update adm1c nano adm1c You should change server_name adm1c.example.com to your name Update index.php nano

null 10 Dec 5, 2022
Learning about - Basic HTML & CSS, JSON, XML, Session & Cookies, CRUD Operations in Php using MySQL and Create MVC from scratch

This Project is based on course CSC 3215. Learning about - Basic HTML & CSS, JSON, XML, Session & Cookies, CRUD Operations in Php using MySQL and Create MVC (Model–View–Controller) from scratch. Just learning about web technologies, Not focusing on UI (Bootstrap or other 3rd-Party UI libraries or frameworks).

Alvi Hasan 5 Sep 21, 2022
Block Session Hijacking in php.

Block Session Hijacking in php. How Does it work? This is an incredibly simple example, that is meant to be worked on. Please Do NOT use this from sto

null 0 Dec 25, 2021
A Simple MVC PHP Framework, integrated with lot of features such as Session, Cookies, Migrations, Database, Factories, Seeding, Bootstrap and Tailwind CSS

Navite A Simple MVC PHP Framework, integrated with lot of features such as Session, Cookies, Migrations, Database, Factories, Seeding, Bootstrap and T

Celionatti 2 Aug 22, 2022
Proxy based Redis cluster solution supporting pipeline and scaling dynamically

Codis is a proxy based high performance Redis cluster solution written in Go. It is production-ready and widely used at wandoujia.com and many compani

null 12.7k Jan 2, 2023
A lightweight queue based on Redis Stream for webman plugin.

workbunny/webman-rqueue ?? A lightweight queue based on Redis Stream for webman plugin. ?? A lightweight queue based on Redis Stream for webman plugin

workbunny 10 Dec 12, 2022
Error handler with PSR-7 support

Jasny Error Handler Error handler with PSR-7 support. Installation The Jasny Error Handler package is available on packagist. Install it using compose

Arnold Daniels 6 Jun 23, 2022
think-exception-handler

ThinkPHP6.0 exception 异常插件 安装 composer require tinywan/think-exception 配置 发布配置 php think tinywan:exception 这将自动生成 config/exception.php 配置文件。 配置异常类 a

 ShaoBo Wan(無尘) 4 Dec 27, 2022