Call to undefined function module_implements
| Project: | APC - Alternative PHP Cache |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | won't fix |
Jump to:
I have problem while using APC Cache.
I get error:
Fatal error: Call to undefined function module_implements() in C:\wos\www\includes\bootstrap.inc on line 735
While bootstrapping DRUPAL_BOOTSTRAP_LATE_PAGE_CACHE Drupal calls variable_init(...).
It looks for variables in cache using cache_get(...). It fails and it tries to log it using watchdog(...) function.
Unfortunatelly watchdog(...) uses module_implements(..) so it can be called only if module.inc has been previously included.
There are 3 possible solutions for this issue:
1. Add if(function_exists(...) in watchdog function in bootstrap.inc
2. Switch theese lines in bootstrap.inc:
// Initialize configuration variables, using values from settings.php if available.
$conf = variable_init(isset($conf) ? $conf : array());
// Load module handling.
require_once './includes/module.inc';
3. Modify logging mechanizm in apc_handle_get(...) in apc.inc
It seems to work if I remove watchdog(...) from apc_gandle_get(...)

#1
+1
#2
subscribe
#3
This module is basically deprecated. I don't plan on continuing development. Please have a look at http://drupal.org/project/cacherouter for APC cache options.
#4
Same issue exists in cacherouter. ;)
Looks like the fix would be a function_exists() check around the module_implements call.