Set expiry time for key in garnet client #445
Unanswered
VartuSharma
asked this question in
Q&A
Replies: 2 comments
-
No its not possible at the time, but if you use StackExchange.Redis as the Service for the Garnet Client (Server), you can use its method wirh StringSetAsync(key, value, TimeSpan.FromMinutes()) to set there an expiration time. |
Beta Was this translation helpful? Give feedback.
0 replies
-
await db.ExecuteForStringResultAsync("EXPIRE", [key, "30", "NX"]); |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is there any way I can set expiration of key while setting the value using garnet.client?
Beta Was this translation helpful? Give feedback.
All reactions