Use an LRU cache to keep memory footprint down