-
-
Notifications
You must be signed in to change notification settings - Fork 7.7k
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
BUG: the "ttl" option of CacheModule doesn't work when use with redis #6804
Comments
Would you like to create a PR for this issue? |
I'm so sorry, i'm a newcomer... i cannot position the bug point in code. |
Hey @DevAngsy, I have checked what is happening here and it's a bug of
What could you do?
|
Thank you @Tony133 🙌 As this doesn't seem to be directly related to Nest, let me close this issue. |
Bug Report
Current behavior
Mini Repo: nestjs-bugs
As shown in the pictures below, default "ttl" option is 30 seconds.
Input Code
The CacheModule:
The Controller:
The redis GUI, as you can see, the value of ttl is -1, it's initial value should be 30:
Expected behavior
If don't use "CacheTTL" decorator, sub-library should properly use defualt "ttl".
Possible Solution
The "cache-manager-ioredis" library accept "option" argument, but value is undefined when use with redis store and do not use
"CacheTTL" decorator.
Environment
The text was updated successfully, but these errors were encountered: