Generate a memory cache key in the implementation of the cache