@highoutput/amqp
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -47,3 +47,2 @@ "use strict"; | ||
logger_1.default.tag(['worker', 'request']).info(request); | ||
const sender = await this.getSender(message.reply_to); | ||
let result = null; | ||
@@ -57,13 +56,16 @@ let error = null; | ||
} | ||
const response = { | ||
correlationId: message.correlation_id, | ||
result: this.options.serialize ? util_1.serialize(result) : result, | ||
error, | ||
timestamp: Date.now(), | ||
}; | ||
logger_1.default.tag(['worker', 'response']).info(request); | ||
sender.send({ | ||
correlation_id: message.correlation_id, | ||
body: response, | ||
}); | ||
if (message.reply_to) { | ||
const response = { | ||
correlationId: message.correlation_id, | ||
result: this.options.serialize ? util_1.serialize(result) : result, | ||
error, | ||
timestamp: Date.now(), | ||
}; | ||
logger_1.default.tag(['worker', 'response']).info(request); | ||
const sender = await this.getSender(message.reply_to); | ||
sender.send({ | ||
correlation_id: message.correlation_id, | ||
body: response, | ||
}); | ||
} | ||
} | ||
@@ -70,0 +72,0 @@ async start() { |
{ | ||
"name": "@highoutput/amqp", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "A simplified abstraction of the AMQP 1.0 protocol", | ||
@@ -52,3 +52,3 @@ "keywords": [ | ||
}, | ||
"gitHead": "24973267d808f94a6a5b1b21c009450fea39449d" | ||
"gitHead": "b7cc3d42f88a1affea58d9440c7b5e54b00aa8d0" | ||
} |
@@ -61,3 +61,2 @@ /* eslint-disable @typescript-eslint/no-non-null-assertion, @typescript-eslint/camelcase */ | ||
max_reconnect_delay: this.options.maxReconnectDelay, | ||
}); | ||
@@ -64,0 +63,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
57377
815