Comparing version 2.0.1 to 2.0.2
@@ -121,3 +121,3 @@ const EventEmitter = require('eventemitter3') | ||
async _setup ({ queue, event }) { | ||
async _setup ({ queue, event, prefetch = 48 }) { | ||
try { | ||
@@ -146,4 +146,7 @@ const worker = await this._remit._workers.acquire() | ||
}) | ||
this._consumer.prefetch(48) | ||
if (prefetch > 0) { | ||
this._consumer.prefetch(prefetch, true) | ||
} | ||
await this._consumer.bindQueue( | ||
@@ -150,0 +153,0 @@ queue, |
@@ -97,3 +97,3 @@ const EventEmitter = require('eventemitter3') | ||
async _setup ({ queue, event }) { | ||
async _setup ({ queue, event, prefetch = 48 }) { | ||
try { | ||
@@ -122,4 +122,7 @@ const worker = await this._remit._workers.acquire() | ||
}) | ||
this._consumer.prefetch(48) | ||
if (prefetch > 0) { | ||
this._consumer.prefetch(prefetch, true) | ||
} | ||
await this._consumer.bindQueue( | ||
@@ -126,0 +129,0 @@ queue, |
{ | ||
"name": "remit", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "A small set of functionality used to create microservices that don't need to be aware of one-another's existence.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -12,3 +12,3 @@ const os = require('os') | ||
host: { | ||
name: os.hostname(), | ||
name: `${os.userInfo().username}@${os.hostname()}`, | ||
platform: `${os.type()}@${os.release()}`, | ||
@@ -15,0 +15,0 @@ pid: process.pid, |
68017
1516