messages-recv: decrease PDO response timeout

This commit is contained in:
Rajeh Taher
2026-01-18 01:34:39 +02:00
parent b1c76ebe2d
commit 83e0f22af8
+3 -3
View File
@@ -151,7 +151,7 @@ export const makeMessagesRecvSocket = (config: SocketConfig) => {
await placeholderResendCache.set(messageKey?.id!, true)
}
await delay(5000)
await delay(2000)
if (!(await placeholderResendCache.get(messageKey?.id!))) {
logger.debug({ messageKey }, 'message received while resend requested')
@@ -169,10 +169,10 @@ export const makeMessagesRecvSocket = (config: SocketConfig) => {
setTimeout(async () => {
if (await placeholderResendCache.get(messageKey?.id!)) {
logger.debug({ messageKey }, 'PDO message without response after 15 seconds. Phone possibly offline')
logger.debug({ messageKey }, 'PDO message without response after 8 seconds. Phone possibly offline')
await placeholderResendCache.del(messageKey?.id!)
}
}, 15_000)
}, 8_000)
return sendPeerDataOperationMessage(pdoMessage)
}