@onlineapps/service-wrapper 2.0.3 → 2.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/ServiceWrapper.js +11 -2
package/package.json
CHANGED
package/src/ServiceWrapper.js
CHANGED
|
@@ -244,12 +244,21 @@ class ServiceWrapper {
|
|
|
244
244
|
queue: `${this.serviceName}.workflow`,
|
|
245
245
|
prefetch: this.config.prefetch || 10,
|
|
246
246
|
durable: true,
|
|
247
|
-
noAck: false
|
|
247
|
+
noAck: false,
|
|
248
|
+
logger: {
|
|
249
|
+
info: (...args) => this.logger.info(...args),
|
|
250
|
+
warn: (...args) => this.logger.warn(...args),
|
|
251
|
+
error: (...args) => this.logger.error(...args),
|
|
252
|
+
debug: (...args) => this.logger.debug(...args)
|
|
253
|
+
}
|
|
248
254
|
});
|
|
249
255
|
await this.mqClient.connect();
|
|
250
256
|
|
|
251
|
-
// Initialize registry client
|
|
257
|
+
// Initialize registry client with required parameters
|
|
252
258
|
this.registryClient = new RegistryConnector.ServiceRegistryClient({
|
|
259
|
+
amqpUrl: rabbitUrl,
|
|
260
|
+
serviceName: this.serviceName,
|
|
261
|
+
version: this.openApiSpec?.info?.version || '1.0.0',
|
|
253
262
|
registryUrl: this.config.registry || process.env.REGISTRY_URL || 'http://localhost:4000',
|
|
254
263
|
logger: this.logger
|
|
255
264
|
});
|