From 06535a37b5682b38e4a1a076b545e7e058f37516 Mon Sep 17 00:00:00 2001 From: syuilo Date: Tue, 17 Apr 2018 08:06:51 +0900 Subject: [PATCH] =?UTF-8?q?=E3=82=AD=E3=83=A5=E3=83=BC=E3=81=AE=E3=83=A1?= =?UTF-8?q?=E3=83=A2=E3=83=AA=E4=BD=BF=E7=94=A8=E9=87=8F=E3=82=92=E5=89=8A?= =?UTF-8?q?=E6=B8=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/queue/index.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/queue/index.ts b/src/queue/index.ts index 94efb3634a..88e475dd5d 100644 --- a/src/queue/index.ts +++ b/src/queue/index.ts @@ -14,7 +14,7 @@ const queue = createQueue({ export function createHttp(data) { return queue .create('http', data) - .attempts(16) + .attempts(8) .backoff({ delay: 16384, type: 'exponential' }); } @@ -24,7 +24,7 @@ export function deliver(user, content, to) { user, content, to - }).save(); + }).removeOnComplete(true).save(); } export default function() { @@ -36,5 +36,6 @@ export default function() { Network.http.max-connections - MozillaZine Knowledge Base http://kb.mozillazine.org/Network.http.max-connections */ - queue.process('http', 256, http); + //queue.process('http', 256, http); + queue.process('http', 128, http); }