ZF-1524: introduction of cache_id_prefix


Patch files are attached to this task to add cache id prefix to Zend_Cache_Core so that it is available to all front and backends.


Assign to Fabien Marty.

ok for 1.1.0 serie

Marking fix version as unknown. Please set fix version when this issue is resolved.

Hey, this is Tony, the one that submitted the original patch for this feature through the mailing list. Do you guys think we can we get this into the 1.5 preview release? And/or, how can I help to make that happen?

I too would like to see this implemented for the 1.5 seriers

is this feature needed for all backends or only for the memcached one ?

FYI, I signed a ZF CLA today and sent it in. Looks like they took care of it, so I'm all set on that front now.

Fabien, in my opinion this cache id prefix is only necessary for the memcached and apc backends.

The file backend already has a prefix of sorts, a "file name" prefix. Doesn't really matter though, cause it serves the same purpose. Even so, might not be a bad idea to change that to a cache id prefix for consistency. Whether its a file name prefix or a cache id prefix, it doesn't really matter for the File backend, because the cacheid is used to create the final file name anyway. Less work if we don't fool with it, but more consistent with the other backends if we do change it ...

The only other two backends are sqlite and Zend Platform. Both of those support tags though, so I don't feel the prefix is necessary. The whole point is to create namespaces with the cache, that's one of the things tags do for you.

I'm willing to finish this task when I have some answers. I'll provide up to date patches for memcached and apc backends, and I'll do unit tests and any docs too.


IMHO, this feature is a sort of namespaces one.

So, it is not logic to introduce this on specific backends.

IMHO, this feature must be in Core.php. In this way, it will be completly transparent for all backends.

Tony, do you want to take care of it (in this way) ?

Fabien, yea, that sounds good. I'm working on it now. I'll submit a patch against the 1.5 preview release very soon.

Removed old patch that was only relevant for memcached backend. New patches are attached now.

Sorry, last comment.

Fabien, I do not believe any additional tests are necessary, so I've attached changes to cache core and documentation updates, for the English version only ...

Let me know if there is anything additional, thanks.

commited in SVN trunk Tony (thanks !)