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
Also for my case, it can't be guaranteed that all the resources will exist in the cache.
Will this work?
When I run the code I get the following warning:
node_redis: Deprecated: The EVAL command contains a argument of type Array.
This is converted to "lock:resource1,lock:resource2" by using .toString() now and will return an error from v.3.0 on.
Please handle this in your code to make sure everything works as you intended it to.
The text was updated successfully, but these errors were encountered:
Hi @ZacharyKearns, your general description here is correct usage of this library. Your example, though, would work just perfectly without locking at all, as deleting redis keys happens atomically already. This library is usually used when you have multi-step asynchronous operations on some shared state. Hope that answers your question!
RE the node_redis error, that indeed looks like a problem. I would highly suggest using ioredis instead.
Hi,
I want to lock multiple resources so they can't be accessed while I am deleting them.
The code looks something like this:
Also for my case, it can't be guaranteed that all the resources will exist in the cache.
Will this work?
When I run the code I get the following warning:
The text was updated successfully, but these errors were encountered: