Share » Forums » Developer » Use some cache in a custom fetch...

Use some cache in a custom fetch function

Use some cache in a custom fetch function

Thursday 01 April 2010 10:08:57 am - 2 replies

Author Message

Bertrand Dunogier

Thursday 01 April 2010 12:06:11 pm

Well, honestly, if you just need to cache temporary data for one run, you should use a global... just centralize the read/write code for these globals so that you can easily refactor it, and prefix your global names with your initials or company acronym... just like we do with eZ. There should be no conflicts this way (not more than with classes, at least :p).

If you want to implement more persistent caching, here are the options I would consider:

  • ezcCache. That's it :p
    We plan on re-implementing most caches using the Cache component from the ezComponents. It has support for hierarchical cache, and already supports standard backends (memcache, APC, files...).
    http://ezcomponents.org/docs/tutorials/Cache

Bertrand Dunogier
eZ Systems Engineering, Lyon
http://twitter.com/bdunogier
http://gplus.to/BertrandDunogier

Jerome Despatis

Thursday 01 April 2010 12:34:28 pm

Ok thanks

I already use it for plain file cache, I've seen memory cache also, let's test that...

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu