doctrine/common — pull request #125 by sobstel (2012-03-28 15:11:55+00:00)
Title: Fix for CacheProvider serious performance issue

Prior implementation for CacheProvider was seriously flawed from performance point of view as each fetch() call results in 2 additional cache storage calls due to $this->getNamespaceId(), which always checks for $namespaceCacheKey (and fetches it if exists, which will be the case for 2nd and next calls).

It is big overhead (3 calls instead just one for each fetch), and actually can be easily solved by memoizing namespace version value.