Hi,
I have a use case where I know some of my endpoints will never have a cache-control header, then the responses from these endpoints are not supposed to be cached on redis by my RESTDataSource implementation.
I noticed that in line 22 of the HTTPCache module a key is always checked to try hit some cached value.
const entry = await this.keyValueCache.get(`httpcache:${cacheKey}`);
Is there any intention to have an available option that allows bypassing this behavior on get method of the RESTDataSource? I think this would be a good option for these cases where it is not necessary to check a cache key before every fetch, given that the value will never be found in the cache.
This has come up for our team as well.
I'd like to see two of the following changes, and would send a PR if approved:
!cacheKey, skip caching entirely.httpcache: if I specify a key. Corporations have key naming requirements we have to follow.
Most helpful comment
This has come up for our team as well.
I'd like to see two of the following changes, and would send a PR if approved:
!cacheKey, skip caching entirely.httpcache:if I specify a key. Corporations have key naming requirements we have to follow.