adding size limit to cache.