Running into something frustrating. Were running a site that is working with Redis with no issues.
Put the APDQC module on and started going through the different configuration/settings and its been very helpful.
When I got to putting in the following:

APDQC - Lock Backend	lock_inc is not set to apdqc.
Inside settings.php add this to the bottom of the file
$conf['lock_inc'] = 'sites/all/modules/contrib/apdqc/apdqc.lock.inc';
$conf['base_lock_inc'] = 'sites/all/modules/contrib/redis/redis.lock.inc';

I updated our system to read:

/*$conf['lock_inc'] = 'sites/all/modules/contrib/redis/redis.lock.inc';*/
$conf['lock_inc'] = 'sites/all/modules/contrib/apdqc/apdqc.lock.inc';
$conf['base_lock_inc'] = 'sites/all/modules/contrib/redis/redis.lock.inc';

Things seem fine and our reports read properly, I then go and run: service php5-fpm restart and site wont load anymore.
The log files read:

2015/09/23 14:34:51 [error] 6861#0: *7863 FastCGI sent in stderr: "PHP message: PHP Fatal error: Class 'base_lock\Redis_Lock' not found in /var/www/prod/docroot/sites/all/modules/contrib/apdqc/apdqc.lock.redis.inc on line 37" while reading response header from upstream, client: XXX.XXX.XXX.XXX, server: oursitename.com, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "oursitename.com"

Anyone else having this problem? Maybe have a suggestion on a workaround?

Comments

Jason Ruyle created an issue. See original summary.

mikeytown2’s picture

What version of the redis module are you using?

  • mikeytown2 committed 98a7e3a on 7.x-1.x
    Issue #2573533 by mikeytown2: Fix redis autoloader for locking.
    
mikeytown2’s picture

Status: Active » Fixed
StatusFileSize
new1.21 KB

I believe this fixes it; if not then this module might not be compatible with redis due to the way locking works in drupal (not an object).

jason ruyle’s picture

I applied these updates and things seem to be working. I used the latest dev release (which looks like has this patch).
Thanks for the help.

jason ruyle’s picture

So I was wrong, it didn't resolve.
This is what I currently have in my settings.php

$conf['redis_client_interface']  = 'PhpRedis';
$conf['session_inc'] = 'sites/all/modules/contrib/apdqc/apdqc.session.inc';
$conf['lock_inc'] = 'sites/all/modules/contrib/apdqc/apdqc.lock.inc';
$conf['base_lock_inc'] = 'sites/all/modules/contrib/redis/redis.lock.inc';
$conf['cache_default_class'] = 'Redis_Cache';
$conf['cache_class_cache_form'] = 'APDQCache';

I also tried both of these options:

$conf['cache_backends'][] = 'sites/all/modules/contrib/apdqc/apdqc.cache.inc';

and

$conf['cache_backends'] = array(
  'sites/all/modules/contrib/redis/redis.autoload.inc',
  'sites/all/modules/contrib/apdqc/apdqc.cache.inc',
);

I'm not sure if I should change my cache_default_class to APDQCache, but really I dont think it matters at this stage. For whatever reason its not picking up the base_lock_inc properly.

Is my base_lock_inc correct? Should it be changed to: 'sites/all/modules/contrib/redis' ?

mikeytown2’s picture

Status: Fixed » Needs work
mikeytown2’s picture

Status: Needs work » Needs review
StatusFileSize
new63.43 KB
new15.87 KB

Got rid of namespaces unless the eval fallback is used; hopefully this takes care of the issue.

The smaller patch ignores whitespace changes

mikeytown2’s picture

Status: Needs review » Fixed

#8 has been committed. Please let me know if this latest change fixes the issues you've been having

  • mikeytown2 committed 11f79cb on 7.x-1.x
    Issue #2573533 by mikeytown2: remove the base_lock namespace due to...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.