Closed (fixed)
Project:
Entity API
Version:
7.x-1.x-dev
Component:
Entity CRUD controller
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
30 Mar 2011 at 19:56 UTC
Updated:
11 Nov 2011 at 10:40 UTC
Jump to comment: Most recent file
Comments
Comment #1
fagoyep, I'd like to see that happen asap. Any tackers?
Comment #2
jamsilver commentedOK, here is a very rudimentary attempt to make 'entity cache' something pluggable and delegates calls to it in all the moments entitycache seems to need them at the moment.
Pretty sure this works at the moment if entitycache's
EntityCacheControllerHelperis passed as the 'entity cache' value inhook_entity_info_alter()as long asEntityCacheControllerHelper's methods are changed from protected to public.Comment #3
plachCrosslinking: #1165930: Compatibility with Entity API.
Comment #4
fagopatch looks good to me. I guess we should add some usage instructions to the README?
Comment #5
quartsize commentedIs it support specifically for Entity cache that is desired, or persistent caching for
EntityAPIController, withEntityCacheControllerHelperas a means to that end?Comment #6
Fidelix commentedDefinitely subscribing!
I'm coming from this issue: #1165930: Compatibility with Entity API
Comment #7
jamsilver commented@quartsize: the approach I took was the more general one. So this patch works persistent caching into EntityAPIController delegating everything to the class found in the 'entity cache' property of the entity info.
Which allows the persistent cache handler to be swapped out if necessary.
Having said that, I made it work with EntityCache in mind, I haven't thought about what other persistent caching mechanisms may exist and may require so any thoughts you have about making it sufficiently flexible are welcome =)
Note, the complimentary issue on entitycache module has been committed (#1165930: Compatibility with Entity API)
Comment #9
andypostSo only README lines are should be done to make this happen. Seem this patch needs reroll but let's test it.
#2: entity-1111120-3-support-for-entitycache.patch queued for re-testing.
Comment #10
fagoentity cache module defines the entity cache property as TRUE / FALSE - let's follow that and just use the class provided by the entity cache module.
Also I'm not keen on introducing a 'entity cache' property supporting arbitrary classes or without any interface or base class to extend. The latter could already be considered bad practice...
Comment #11
fagook, I've implemented it that way and committed it. See attached patch.
Comment #12
amateescu commentedI can't see this in the repository.. maybe you forgot to push? :)
Comment #13
fagoexactly.. sry, pushed it now.