Skip to content
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

Add generalized caching layer for Assets #23

Closed
jakemac53 opened this issue Feb 2, 2016 · 1 comment · Fixed by #29
Closed

Add generalized caching layer for Assets #23

jakemac53 opened this issue Feb 2, 2016 · 1 comment · Fixed by #29
Labels
type-enhancement A request for a change that isn't a bug

Comments

@jakemac53
Copy link
Contributor

I think this should just be implemented as a general CachedAssetReader which takes an instance of AssetReader, and delegates to that whenever there isn't a cached asset available. There would also be a CachedAssetWriter which takes an instance of AssetWriter and a CachedAssetReader (so it can populate the readers cache with new values).

Another option is to just implement an AssetCache class which gets passed into individual implementations of AssetReader/AssetWriter, but then each of those implementations needs to know about the cache.

@jakemac53 jakemac53 added this to the v0.1.1 release milestone Feb 2, 2016
@jakemac53
Copy link
Contributor Author

Or maybe a combo, so CachedAssetReader and CachedAssetWriter each take an AssetCache.

If AssetCaches were composable this would also allow you to have a cache per phase which might be interesting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants