Redis Cache Extension - ClearTags

Hey all knowing ones. I was the original requester for the feature in query cache for Tags. I make significant use of tags in my query caching. I originally implemented Query Caching and Tags using MongoDB due to the TTL indexes and Indexes of arrays allowing me to clear cache easily by doing a $in:[listOfTags].

I recently rolled my own version of redis caching to support tags. Then realized that there is a Redis extension for caching.

When I tried to implement the Mongo Caching extension the clearing of tags brought the system to its knees, which I believe is due to the fact that when clearing tags you would need to loop through every single cache item and delete it if the cache is tagged.

One question is: Does the Redis cache work like that too or is there some other way of storing references for the tags to cache records?

In my implementation I use sets to manage the list of cache ids that are for each tag, so I am only looping through the small list of ids that are in the set for that tag. I set the ttl for both the tags and the cache item so redis stays small.

Another question: is Redis cache extension using any type of compression for the data? Redis does not use any compression and leaves it up to the implementation to do any kind of data compression.

In my implementation I used Snappy to compress the recordset so that it uses far less space. This was originally done in Mongo due to mongos limitation of 16mb document.

I would much rather use a build in extension then use my custom one if possible, but performance is a major concern with clearing tags since my query cache hold a consistent 100k cache records and spinning through each of those would be way too slow.