Closed (fixed)
Project:
Memcache API and Integration
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
2 Mar 2011 at 13:44 UTC
Updated:
26 Aug 2011 at 12:02 UTC
Jump to comment: Most recent file
Comments
Comment #1
jeremy commentedThe 7.x version of this module is deployed in many places. Be sure you're using -beta3 or the 7.x-1.x-dev branch. Your changes are wrong: memcache.inc is properly named. And memcache should not depend on memcache_admin. See the INSTALL.txt file for directions on how to use memcache.
Comment #2
mente commentedI'm sure, what I've checked. Actually, memcache works, but installation of the module is not user-friendly. Include file in settings.php, instead of using modules page. Why do we need modules then? Just include file and that's it. I thought drupal-way was to use admin panel and not vim with ftp.
Patch provides user-friendly installation, bringing the same functionality. Explain me, please, where I'm wrong.
If you think current deployment method is good - ok, let it be. At least review this patch for MemCacheDrupal::getMultiple().
Comment #3
jeremy commentedRe-opening so we remember to take a look. For it to be merged it would be preferred that you break out each functional difference into an individual patch. One big patch that does a bunch of unrelated things 1) may never actually get reviewed, 2) is much less likely to get merged.
Comment #4
catchYou can't use modules for caching backends - the page cache, variables and system_list cache (which includes module_list()) are all requested before modules are loaded.
Comment #5
catchRe-titling for reduced scope.
Comment #6
berdirHere is a new patch that fixes it directly in dmemcache.inc.
Comment #7
berdirI figured out that $value->cid already contains the correct cid, so that $reverse stuff isn't necessary.
I also found a second bug: $cids is not correctly changed because you are trying to delete entries from which the key is the $cid, but the key is just an integer, the values are the cids.
New patches fixes both.
Without this patch, both the fields cache from field_storage_sql and export defaults cache from ctools are completely broken and rewrite their cache *on every single site*, which takes >0.5s on every page, making the site twice as slow as it is without memcached :)
How can anyone actually use this module... ;)
Comment #8
berdirAnd now with tests!
I had some trouble having the tests actually use MemCacheDrupal, I had to manually set the default value in _cache_get_object(), Simpletest seems to have somehow overriden what I set in settings.php.
The tests fail horribly without this patch :)
All I did in the tests was to prefix item1 and item2 with test:, so that the $full_key is urlencoded and different and I verified that $items_ids was changed correctly.
Comment #9
catchThanks for the patch, and the tests! Committed and pushed.