Caching the keys