@unito/integration-sdk 1.0.22 → 1.0.23
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/dist/src/index.cjs +8 -5
- package/dist/src/integration.js +8 -5
- package/package.json +1 -1
- package/src/integration.ts +9 -5
package/dist/src/index.cjs
CHANGED
|
@@ -997,14 +997,10 @@ class Integration {
|
|
|
997
997
|
app.use(express.json());
|
|
998
998
|
// Must be one of the first handlers (to catch all the errors).
|
|
999
999
|
app.use(middleware$2);
|
|
1000
|
+
// Instantiate internal middlewares.
|
|
1000
1001
|
app.use(middleware);
|
|
1001
1002
|
app.use(middleware$a);
|
|
1002
1003
|
app.use(middleware$9);
|
|
1003
|
-
app.use(middleware$8);
|
|
1004
|
-
app.use(middleware$6);
|
|
1005
|
-
app.use(middleware$5);
|
|
1006
|
-
app.use(middleware$4);
|
|
1007
|
-
app.use(middleware$7);
|
|
1008
1004
|
// Making sure we log all incoming requests (except to '/health'), prior any processing.
|
|
1009
1005
|
app.use((req, res, next) => {
|
|
1010
1006
|
if (req.originalUrl !== '/health') {
|
|
@@ -1012,6 +1008,13 @@ class Integration {
|
|
|
1012
1008
|
}
|
|
1013
1009
|
next();
|
|
1014
1010
|
});
|
|
1011
|
+
// Instantiate application middlewares. These can throw, so they have an implicit dependency on the internal
|
|
1012
|
+
// middlewares such as the logger, the correlationId, and the error handling.
|
|
1013
|
+
app.use(middleware$8);
|
|
1014
|
+
app.use(middleware$6);
|
|
1015
|
+
app.use(middleware$5);
|
|
1016
|
+
app.use(middleware$4);
|
|
1017
|
+
app.use(middleware$7);
|
|
1015
1018
|
// Load handlers as needed.
|
|
1016
1019
|
if (this.handlers.length) {
|
|
1017
1020
|
for (const handler of this.handlers) {
|
package/dist/src/integration.js
CHANGED
|
@@ -114,14 +114,10 @@ export default class Integration {
|
|
|
114
114
|
app.use(express.json());
|
|
115
115
|
// Must be one of the first handlers (to catch all the errors).
|
|
116
116
|
app.use(finishMiddleware);
|
|
117
|
+
// Instantiate internal middlewares.
|
|
117
118
|
app.use(requestStartTimeMiddleware);
|
|
118
119
|
app.use(correlationIdMiddleware);
|
|
119
120
|
app.use(loggerMiddleware);
|
|
120
|
-
app.use(credentialsMiddleware);
|
|
121
|
-
app.use(secretsMiddleware);
|
|
122
|
-
app.use(filtersMiddleware);
|
|
123
|
-
app.use(selectsMiddleware);
|
|
124
|
-
app.use(signalMiddleware);
|
|
125
121
|
// Making sure we log all incoming requests (except to '/health'), prior any processing.
|
|
126
122
|
app.use((req, res, next) => {
|
|
127
123
|
if (req.originalUrl !== '/health') {
|
|
@@ -129,6 +125,13 @@ export default class Integration {
|
|
|
129
125
|
}
|
|
130
126
|
next();
|
|
131
127
|
});
|
|
128
|
+
// Instantiate application middlewares. These can throw, so they have an implicit dependency on the internal
|
|
129
|
+
// middlewares such as the logger, the correlationId, and the error handling.
|
|
130
|
+
app.use(credentialsMiddleware);
|
|
131
|
+
app.use(secretsMiddleware);
|
|
132
|
+
app.use(filtersMiddleware);
|
|
133
|
+
app.use(selectsMiddleware);
|
|
134
|
+
app.use(signalMiddleware);
|
|
132
135
|
// Load handlers as needed.
|
|
133
136
|
if (this.handlers.length) {
|
|
134
137
|
for (const handler of this.handlers) {
|
package/package.json
CHANGED
package/src/integration.ts
CHANGED
|
@@ -130,14 +130,10 @@ export default class Integration {
|
|
|
130
130
|
// Must be one of the first handlers (to catch all the errors).
|
|
131
131
|
app.use(finishMiddleware);
|
|
132
132
|
|
|
133
|
+
// Instantiate internal middlewares.
|
|
133
134
|
app.use(requestStartTimeMiddleware);
|
|
134
135
|
app.use(correlationIdMiddleware);
|
|
135
136
|
app.use(loggerMiddleware);
|
|
136
|
-
app.use(credentialsMiddleware);
|
|
137
|
-
app.use(secretsMiddleware);
|
|
138
|
-
app.use(filtersMiddleware);
|
|
139
|
-
app.use(selectsMiddleware);
|
|
140
|
-
app.use(signalMiddleware);
|
|
141
137
|
|
|
142
138
|
// Making sure we log all incoming requests (except to '/health'), prior any processing.
|
|
143
139
|
app.use((req, res, next) => {
|
|
@@ -147,6 +143,14 @@ export default class Integration {
|
|
|
147
143
|
next();
|
|
148
144
|
});
|
|
149
145
|
|
|
146
|
+
// Instantiate application middlewares. These can throw, so they have an implicit dependency on the internal
|
|
147
|
+
// middlewares such as the logger, the correlationId, and the error handling.
|
|
148
|
+
app.use(credentialsMiddleware);
|
|
149
|
+
app.use(secretsMiddleware);
|
|
150
|
+
app.use(filtersMiddleware);
|
|
151
|
+
app.use(selectsMiddleware);
|
|
152
|
+
app.use(signalMiddleware);
|
|
153
|
+
|
|
150
154
|
// Load handlers as needed.
|
|
151
155
|
if (this.handlers.length) {
|
|
152
156
|
for (const handler of this.handlers) {
|