New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LRU store cache #223
LRU store cache #223
Conversation
zarr/storage.py
Outdated
with self._mutex: | ||
if self._keys_cache is None: | ||
self._keys_cache = list(self._store.keys()) | ||
return iter(self._keys_cache) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should probably move this under the mutex lock.
cc @jhamman, @mrocklin, this PR provides another strategy for improving performance with cloud stores, adding a |
This PR adds a new
zarr.storage.LRUStoreCache
class which can be used as a cache layer for slow stores (e.g., stores accessed via network).Also in developing this PR some inconsistencies in the way that
zarr.storage.getsize()
was implemented for different store types came to light and have been fixed.TODO: