Closed (fixed)
Project:
Block Cache Alter
Version:
6.x-1.3
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
6 May 2009 at 14:51 UTC
Updated:
22 Jun 2009 at 14:50 UTC
Hi,
With this new release the blocks created with views aren't being cached. Using devel module I can see that the function cache_set() is updating the cache of that block every time the page loads.
Any ideas?
Thanks,
introfini
Comments
Comment #1
swentel commentedI'll look into that this weekend. Have you applied one of the patches also that came with the module?
Comment #2
introfini commentedYes I did.
Thanks,
introfini
Comment #3
introfini commentedI'm trying to debug this..
blockcache_alter_block_view should be called every time a module is displayed, correct?
Comment #4
introfini commentedProblem solved. it was a conflict with another module.
Thanks and sorry for taking your time.
introfini
Comment #5
dropchew commentedHi,
I have this problem too but only using
It even increases the no. of queries to perform compared to
However, the block is cached when displaying in a region, so my guess its not modules conflict.
My code is something like this,
Thanks and its a great module!
Comment #6
dropchew commentedComment #7
introfini commented@dropchew: is that a clean installation or an upgrade from D5?
introfini
Comment #8
dropchew commentedIts a clean installation for D6, 1st time use. I checked the results using devel and realise using the modified block snippet performs 1 more query than the original.
Comment #9
introfini commentedIf you are user number 1, that's normal. If I'm not mistaken the user 1 has no cache enable in the module by design.
introfini
Comment #10
dropchew commentedNope, I am logging as a registered role with access to devel. Just tried again this morning and having the same result.
Btw I think _blockcache_alter_get_cache_id is the extra query being called. Thanks.
Comment #11
liliplanet commentedsubscribe, thx!
Comment #12
swentel commented@dropchew, I'll investigate the issue further this weekend.
Comment #13
dropchew commentedThanks swentel. Appreciate that.
Comment #14
swentel commented@dropchew : tested it on my local machine here. I created a block in views, went to block administration and put caching mode on 'PER PAGE' for that block, enabled block caching on the performance page and added dsm in the 'blockcache_alter_block_view' function as you can see underneath.
I had a menu item with a callback which simply did the module_invoke and return the data.
Everything went fine, the first time (as a normal user) I got the 'not from cache' message, on reload the 'from cache' message and the cache_block table had following entry: views:RandomLijst-block_1: - [BLOB - 2,4 KB] , so I'm not sure what goes wrong with your code.
(Apart from that, the cid parts is empty, that might be another problem, but not related to this issue)
Comment #15
dropchew commentedHi swentel,
I just tried it again using your method and it works. Not sure why it doesn't work for me before. I notice also it will be cached whether or not if you went to block administration and put caching mode on. Thanks and sorry for taking your time.