• Resolved jkenzer

    (@jkenzer)


    I just switched from predis to phpredis as my client to hopefully fix some memory issues. On the admin screen for the redis plugin, it reports “Client: PECL Extension (v2.2.8)” and when I use Debug Bar in admin, I get “Redis Client: PECL Extension (v2.2.8)” in the Object Cache section. However, when I view any page on the front end, Debug Bar reports “Redis Client: Predis (v1.1.1)” I tried flushing the object cache with no success. Is this normal behavior or should they both report the same client?

    https://ww.wp.xz.cn/plugins/redis-cache/

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Till Krüss

    (@tillkruess)

    Weird. You defined the WP_REDIS_CLIENT constant and it’s set to pecl?

    Thread Starter jkenzer

    (@jkenzer)

    Yes, I have:

    define(‘WP_REDIS_CLIENT’, ‘pecl’);

    Thread Starter jkenzer

    (@jkenzer)

    I do have W3 Total Cache set up for page caching but I don’t have any of the object caching setup through there. Not sure of that would cause some kind of conflict?

    Plugin Author Till Krüss

    (@tillkruess)

    They shouldn’t conflict and it does sound like a page cache issue. Try disabling all W3 Total Cache modules and see if it’s displayed correctly then.

    Thread Starter jkenzer

    (@jkenzer)

    I completely disabled W3 Total Cache and had the same results. Is it possible that Debug Bar is just reporting the wrong client?

    Plugin Author Till Krüss

    (@tillkruess)

    What happens if you delete/rename the includes/predis.php file from the plugin folder and then open Debug Bar on the frontend?

    Thread Starter jkenzer

    (@jkenzer)

    I get the following error on the front end only (back end worked fine):

    Warning: require_once(/path-to/plugins/redis-cache/includes/predis.php): failed to open stream: No such file or directory in /path-to/wordpress/wp-content/object-cache.php on line 409

    Fatal error: require_once(): Failed opening required ‘/path-to/plugins/redis-cache/includes/predis.php’ (include_path=’.:/usr/local/lib/php’) in /path-to/wordpress/wp-content/object-cache.php on line 409

    Obviously I substituted the real path with “path-to”

    Thread Starter jkenzer

    (@jkenzer)

    OK, I tracked it down to line 353 of object-cache.php. It’s failing on the “class_exists( ‘Redis’ )” check.

    Any thoughts from here?

    Plugin Author Till Krüss

    (@tillkruess)

    Great. If the class Redis does not exist, then you need install the PhpRedis extension on your server.

    Thread Starter jkenzer

    (@jkenzer)

    Yeah, I was confused because it appeared to be working in the admin area, but it must have just been reporting incorrectly. I got the extension loaded in php.ini and now it works correctly. Thanks.

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘Two Different Clients Reported’ is closed to new replies.