Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Zend cache #62

wants to merge 5 commits into


None yet
2 participants

zircote commented May 18, 2012

Implemented support for cache cleaning via the Rediska_Zend_Cache_Backend_Redis adapter.

Methods now active are:

  • getIds
  • getTags
  • getIdsMatchingTags
  • getIdsNotMatchingTags
  • getIdsMatchingAnyTags

Method getMetadatas now returns any associated tags as well as selective cache cleaning as defined by the Zend_Cache_Backend_ExtendedInterface

zircote added some commits May 18, 2012

Added support to tags with the `Zend_Cache_Backend`:
This will use sets, intersects, unions and pattern searching of sets to determine the list of IDs. Cleaning utilizes pipelining to bulk clean IDs from the store.
fixed tags in `getMetadata` method
updated the unit test for the metadata
minor fixes relating to `ids not matching tags`
changes to substr -vs- substr for key parsing
refined the array_map and added `_filterIds` methods
This supports the filtering of `getIds` in various locations.

Change const prefixes to backend options

array_map ?

and after: if (!empty($matchedTags)) {
and return result of instersect without conditions

Hash with 4 fields for storing data looks better (and not need self::REDISKA_TAGS_IDS . $id):

  1. tags
  2. currentTime
  3. lifetime
  4. data

And use transaction for saving data and additional info

And you must check prev data with same id and add/remove tags

You need something like garbige collector for clean tags for expired keys


shumkov commented May 19, 2012

Hi, very glad to see you here! Thank you for you work, but I'm have some comments for you code. See code comments.


zircote commented May 19, 2012

@shumkov great feedback, thank you. I will close this PR address the comments and resubmit at another time when I have incorporated these changes.

@zircote zircote closed this May 19, 2012


shumkov commented May 19, 2012


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment