You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
it can no longer be instantiated this way and must now be instantiated before passing it to "cache-manager" (see current README usage).
However, the implementation of this module clearly expects to receive args from the cache-manager when instantiating (e.g. isCacheableValuehere). These are args that are not part of the input to the rediStore fn in the typings from this module (nor in the DefinitelyTyped types), but rather that are meant to be passed to the caching fn of cache-manager which will then pass it in to the factory method as seen in its source here (note that this is the older v4.0.1, which is the latest that is compatible with the latest v3.0.1 of this package).
I am guessing the usage of the factory method was removed, even though if it is clearly how cache-manager expects to integrate with stores, because instantiating the Redis store became an async process as another one of the breaking changes in 3.0.0.
Why is the isCacheableValue and other args still referenced when instantiating the store if they are not expected to be passed in from caching fn?
How are we even supposed to pass these args in then? Directly when instantiating the store (should the types then be updated?)
In general, should "cache-manager" caching function be made to handle async factory methods so that prior usage can be reverted?
The text was updated successfully, but these errors were encountered:
v3.0.0 introduced a breaking change where instead of the module exporting a default:
such that the store can be instantiated with the factory method like:
it can no longer be instantiated this way and must now be instantiated before passing it to "cache-manager" (see current README usage).
However, the implementation of this module clearly expects to receive args from the cache-manager when instantiating (e.g.
isCacheableValue
here). These are args that are not part of the input to therediStore
fn in the typings from this module (nor in the DefinitelyTyped types), but rather that are meant to be passed to thecaching
fn ofcache-manager
which will then pass it in to the factory method as seen in its source here (note that this is the older v4.0.1, which is the latest that is compatible with the latest v3.0.1 of this package).I am guessing the usage of the factory method was removed, even though if it is clearly how
cache-manager
expects to integrate with stores, because instantiating the Redis store became an async process as another one of the breaking changes in 3.0.0.Why is the
isCacheableValue
and other args still referenced when instantiating the store if they are not expected to be passed in fromcaching
fn?How are we even supposed to pass these args in then? Directly when instantiating the store (should the types then be updated?)
In general, should "cache-manager"
caching
function be made to handle async factory methods so that prior usage can be reverted?The text was updated successfully, but these errors were encountered: