@onlineapps/service-wrapper 2.1.3 → 2.1.7

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onlineapps/service-wrapper",
3
- "version": "2.1.3",
3
+ "version": "2.1.7",
4
4
  "description": "Thin orchestration layer for microservices - delegates all infrastructure concerns to specialized connectors",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -558,24 +558,9 @@ class ServiceWrapper {
558
558
  // Logger is now available, use it
559
559
  this.logger.info('Monitoring connector initialized', { logsDir });
560
560
 
561
- // Add monitoring middleware to Express app
562
- if (this.app) {
563
- this.app.use((req, res, next) => {
564
- const start = Date.now();
565
-
566
- res.on('finish', () => {
567
- const duration = Date.now() - start;
568
- this.monitoring?.info && this.monitoring.info('Request processed', {
569
- method: req.method,
570
- path: req.path,
571
- statusCode: res.statusCode,
572
- duration
573
- });
574
- });
575
-
576
- next();
577
- });
578
- }
561
+ // NOTE: HTTP logging middleware is applied directly in service's app.js
562
+ // using middlewares/httpLogging.js with lazy logger access via lib/logger.js
563
+ // Configuration is in conn-config/config.json -> wrapper.logging (for reference)
579
564
  }
580
565
 
581
566
  /**
package/src/index.js CHANGED
@@ -18,8 +18,11 @@ const { ConfigLoader } = require('./ConfigLoader');
18
18
  // - WorkflowProcessor -> @onlineapps/conn-orch-orchestrator
19
19
  // - ApiCaller -> @onlineapps/conn-orch-api-mapper
20
20
 
21
+ // Note: HTTP logging middleware is now in each service's middlewares/httpLogging.js
22
+ // It uses lazy logger access via lib/logger.js (set after wrapper.initialize())
23
+
21
24
  module.exports = ServiceWrapper;
22
25
  module.exports.ServiceWrapper = ServiceWrapper;
23
26
  module.exports.ConfigLoader = ConfigLoader;
24
27
  module.exports.default = ServiceWrapper;
25
- module.exports.VERSION = '2.1.2';
28
+ module.exports.VERSION = '2.1.6';