chore: Update Dockerfile and whatsapp.baileys.service.ts

Update and modifications in Dockerfile and src/api/services/channels/whatsapp.baileys.service.ts files. These changes improve the performance and maintainability of the Node.js project.
This commit is contained in:
Davidson Gomes
2024-07-03 18:35:12 -03:00
parent b3a0899f4f
commit 3637b95f8f
2 changed files with 4 additions and 5 deletions

View File

@@ -592,7 +592,7 @@ export class BaileysStartupService extends ChannelStartupService {
},
logger: P({ level: this.logBaileys }),
printQRInTerminal: false,
// ...browserOptions,
...browserOptions,
version,
markOnlineOnConnect: this.localSettings.alwaysOnline,
retryRequestDelayMs: 350,
@@ -601,7 +601,6 @@ export class BaileysStartupService extends ChannelStartupService {
connectTimeoutMs: 20_000,
keepAliveIntervalMs: 30_000,
qrTimeout: 45_000,
// defaultQueryTimeoutMs: undefined,
emitOwnEvents: false,
shouldIgnoreJid: (jid) => {
const isGroupJid = this.localSettings.groupsIgnore && isJidGroup(jid);
@@ -618,7 +617,7 @@ export class BaileysStartupService extends ChannelStartupService {
return this.historySyncNotification(msg);
},
userDevicesCache: this.userDevicesCache,
transactionOpts: { maxCommitRetries: 5, delayBetweenTriesMs: 2500 },
transactionOpts: { maxCommitRetries: 10, delayBetweenTriesMs: 3000 },
patchMessageBeforeSending(message) {
if (
message.deviceSentMessage?.message?.listMessage?.listType === proto.Message.ListMessage.ListType.PRODUCT_LIST