mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-28 23:01:09 +03:00
Merge pull request #1633 from fletch-ai/bugfix/RedisCache-TTL
Bugfix/Switching Redis TTL from EX to PX to match TTL in milliseconds
This commit is contained in:
@@ -131,7 +131,7 @@ class RedisCache implements INode {
|
|||||||
for (let i = 0; i < value.length; i += 1) {
|
for (let i = 0; i < value.length; i += 1) {
|
||||||
const key = getCacheKey(prompt, llmKey, String(i))
|
const key = getCacheKey(prompt, llmKey, String(i))
|
||||||
if (ttl) {
|
if (ttl) {
|
||||||
await client.set(key, JSON.stringify(serializeGeneration(value[i])), 'EX', parseInt(ttl, 10))
|
await client.set(key, JSON.stringify(serializeGeneration(value[i])), 'PX', parseInt(ttl, 10))
|
||||||
} else {
|
} else {
|
||||||
await client.set(key, JSON.stringify(serializeGeneration(value[i])))
|
await client.set(key, JSON.stringify(serializeGeneration(value[i])))
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user