@mojaloop/sdk-scheme-adapter 24.11.0-snapshot.2 → 24.11.0-snapshot.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/.yarn/cache/@mojaloop-central-services-logger-npm-11.10.0-b889b58367-f062b89e9e.zip +0 -0
- package/.yarn/cache/{@mojaloop-central-services-shared-npm-18.33.0-eee3a0674c-98d4f0e2ce.zip → @mojaloop-central-services-shared-npm-18.33.2-ae721deeeb-a80777e9e9.zip} +0 -0
- package/.yarn/cache/{@types-node-npm-24.5.1-e2de7d4e53-1dd21dffe0.zip → @types-node-npm-24.5.2-7697d08520-a497aea88a.zip} +0 -0
- package/.yarn/cache/{ts-jest-npm-29.4.2-1fc50073bc-09494224db.zip → ts-jest-npm-29.4.3-8668f32a0f-818bf5ffca.zip} +0 -0
- package/.yarn/install-state.gz +0 -0
- package/modules/api-svc/package.json +3 -3
- package/modules/api-svc/src/lib/model/InboundTransfersModel.js +31 -31
- package/modules/outbound-command-event-handler/package.json +4 -4
- package/modules/outbound-domain-event-handler/package.json +3 -3
- package/modules/private-shared-lib/package.json +4 -4
- package/package.json +3 -3
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/.yarn/install-state.gz
CHANGED
|
Binary file
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mojaloop/sdk-scheme-adapter-api-svc",
|
|
3
|
-
"version": "21.0.0-snapshot.
|
|
3
|
+
"version": "21.0.0-snapshot.63",
|
|
4
4
|
"description": "An adapter for connecting to Mojaloop API enabled switches.",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"types": "src/index.d.ts",
|
|
@@ -66,9 +66,9 @@
|
|
|
66
66
|
"@koa/cors": "5.0.0",
|
|
67
67
|
"@mojaloop/api-snippets": "18.1.1",
|
|
68
68
|
"@mojaloop/central-services-error-handling": "13.1.2",
|
|
69
|
-
"@mojaloop/central-services-logger": "11.
|
|
69
|
+
"@mojaloop/central-services-logger": "11.10.0",
|
|
70
70
|
"@mojaloop/central-services-metrics": "12.7.1",
|
|
71
|
-
"@mojaloop/central-services-shared": "18.33.
|
|
71
|
+
"@mojaloop/central-services-shared": "18.33.2",
|
|
72
72
|
"@mojaloop/event-sdk": "14.7.0",
|
|
73
73
|
"@mojaloop/logging-bc-client-lib": "0.5.8",
|
|
74
74
|
"@mojaloop/ml-schema-transformer-lib": "2.7.8",
|
|
@@ -530,6 +530,7 @@ class InboundTransfersModel {
|
|
|
530
530
|
// Mark as notified to prevent duplicate notification
|
|
531
531
|
await this._cache.set(cacheKey, true, 60);
|
|
532
532
|
// Send notification to payee
|
|
533
|
+
this._logger.isInfoEnabled && this._logger.push({ transferId }).info('Received transfer callback for GET /transfers/{ID} request, sending notification to payee');
|
|
533
534
|
await this.sendNotificationToPayee(message.data.body, transferId);
|
|
534
535
|
break;
|
|
535
536
|
}
|
|
@@ -1042,8 +1043,8 @@ class InboundTransfersModel {
|
|
|
1042
1043
|
log.verbose('sendFxPutNotificationToBackend body sent to cc: ', { responseBody });
|
|
1043
1044
|
|
|
1044
1045
|
const { enabled, maxRetries, retryDelayMs, maxRetryDelayMs, backoffFactor } = this._backendRequestRetry || {};
|
|
1045
|
-
let res;
|
|
1046
1046
|
const shouldRetry = enabled !== false; // default to true if not set
|
|
1047
|
+
let res;
|
|
1047
1048
|
|
|
1048
1049
|
if (shouldRetry) {
|
|
1049
1050
|
const operation = retry.operation({
|
|
@@ -1056,30 +1057,28 @@ class InboundTransfersModel {
|
|
|
1056
1057
|
await new Promise((resolve) => {
|
|
1057
1058
|
operation.attempt(async (currentAttempt) => {
|
|
1058
1059
|
try {
|
|
1060
|
+
log.verbose(`putFxTransfersNotification attempt ${currentAttempt} for conversionId ${conversionId}`);
|
|
1059
1061
|
res = await this._backendRequests.putFxTransfersNotification(responseBody, conversionId);
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
log.
|
|
1064
|
-
|
|
1065
|
-
resolve();
|
|
1066
|
-
}
|
|
1062
|
+
// Consider success as long as it doesn't throw
|
|
1063
|
+
// `sendRequest` only seems to return `data` of the request which could
|
|
1064
|
+
// be empty for a 200 response
|
|
1065
|
+
log.verbose(`putFxTransfersNotification attempt ${currentAttempt} succeeded for conversionId ${conversionId}`);
|
|
1066
|
+
resolve();
|
|
1067
1067
|
} catch (err) {
|
|
1068
1068
|
log.warn(`putFxTransfersNotification attempt ${currentAttempt} threw error, retrying...`, err);
|
|
1069
1069
|
if (!operation.retry(err)) {
|
|
1070
|
+
log.verbose(`putFxTransfersNotification giving up after ${currentAttempt} attempts`);
|
|
1070
1071
|
resolve();
|
|
1071
1072
|
}
|
|
1072
1073
|
}
|
|
1073
1074
|
});
|
|
1074
1075
|
});
|
|
1075
|
-
|
|
1076
|
-
if (!res) {
|
|
1077
|
-
log.error(`putFxTransfersNotification failed after ${operation.attempts()} attempts`);
|
|
1078
|
-
}
|
|
1079
1076
|
} else {
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1077
|
+
try {
|
|
1078
|
+
log.verbose(`putFxTransfersNotification no-retry mode for conversionId ${conversionId}`);
|
|
1079
|
+
res = await this._backendRequests.putFxTransfersNotification(responseBody, conversionId);
|
|
1080
|
+
} catch (err) {
|
|
1081
|
+
log.error('putFxTransfersNotification failed', err);
|
|
1083
1082
|
}
|
|
1084
1083
|
}
|
|
1085
1084
|
return res;
|
|
@@ -1091,6 +1090,7 @@ class InboundTransfersModel {
|
|
|
1091
1090
|
* Forwards Switch notification for fulfiled transfer to the DFSP backend, when acting as a payee
|
|
1092
1091
|
*/
|
|
1093
1092
|
async sendNotificationToPayee(body, transferId) {
|
|
1093
|
+
const log = this._logger.child({ transferId });
|
|
1094
1094
|
try {
|
|
1095
1095
|
// load any cached state for this transfer e.g. quote request/response etc...
|
|
1096
1096
|
this.data = await this._load(transferId);
|
|
@@ -1139,32 +1139,32 @@ class InboundTransfersModel {
|
|
|
1139
1139
|
await new Promise((resolve) => {
|
|
1140
1140
|
operation.attempt(async (currentAttempt) => {
|
|
1141
1141
|
try {
|
|
1142
|
+
log.verbose(`putTransfersNotification attempt ${currentAttempt} for transferId ${transferId}`);
|
|
1142
1143
|
res = await this._backendRequests.putTransfersNotification(this.data, transferId);
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
resolve();
|
|
1151
|
-
}
|
|
1144
|
+
// Consider success as long as it doesn't throw
|
|
1145
|
+
// `sendRequest` only seems to return `data` of the request which could
|
|
1146
|
+
// be empty for a 200 response
|
|
1147
|
+
const cacheKey = `patchNotificationSent_${transferId}`;
|
|
1148
|
+
await this._cache.set(cacheKey, true, 60);
|
|
1149
|
+
log.verbose(`putTransfersNotification attempt ${currentAttempt} succeeded for transferId ${transferId}`);
|
|
1150
|
+
resolve();
|
|
1152
1151
|
} catch (err) {
|
|
1153
1152
|
this._logger.warn(`putTransfersNotification attempt ${currentAttempt} threw error, retrying...`, err);
|
|
1154
1153
|
if (!operation.retry(err)) {
|
|
1154
|
+
log.verbose(`putTransfersNotification giving up after ${currentAttempt} attempts`);
|
|
1155
1155
|
resolve();
|
|
1156
1156
|
}
|
|
1157
1157
|
}
|
|
1158
1158
|
});
|
|
1159
1159
|
});
|
|
1160
|
-
|
|
1161
|
-
if (!res) {
|
|
1162
|
-
this._logger.error(`putTransfersNotification failed after ${operation.attempts()} attempts`);
|
|
1163
|
-
}
|
|
1164
1160
|
} else {
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
this.
|
|
1161
|
+
try {
|
|
1162
|
+
log.verbose(`putTransfersNotification no-retry mode for transferId ${transferId}`);
|
|
1163
|
+
res = await this._backendRequests.putTransfersNotification(this.data, transferId);
|
|
1164
|
+
const cacheKey = `patchNotificationSent_${transferId}`;
|
|
1165
|
+
await this._cache.set(cacheKey, true, 60);
|
|
1166
|
+
} catch (err) {
|
|
1167
|
+
this._logger.error('putTransfersNotification failed', err);
|
|
1168
1168
|
}
|
|
1169
1169
|
}
|
|
1170
1170
|
return res;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mojaloop/sdk-scheme-adapter-outbound-command-event-handler",
|
|
3
|
-
"version": "0.3.0-snapshot.
|
|
3
|
+
"version": "0.3.0-snapshot.59",
|
|
4
4
|
"description": "Mojaloop sdk scheme adapter command event handler",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://github.com/mojaloop/sdk-scheme-adapter/",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@mojaloop/api-snippets": "18.1.1",
|
|
45
|
-
"@mojaloop/central-services-shared": "18.33.
|
|
45
|
+
"@mojaloop/central-services-shared": "18.33.2",
|
|
46
46
|
"@mojaloop/logging-bc-client-lib": "0.5.8",
|
|
47
47
|
"@mojaloop/logging-bc-public-types-lib": "0.5.6",
|
|
48
48
|
"@mojaloop/sdk-scheme-adapter-private-shared-lib": "workspace:^",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"@types/convict": "6.1.6",
|
|
61
61
|
"@types/express": "5.0.3",
|
|
62
62
|
"@types/jest": "30.0.0",
|
|
63
|
-
"@types/node": "24.5.
|
|
63
|
+
"@types/node": "24.5.2",
|
|
64
64
|
"@types/node-cache": "4.2.5",
|
|
65
65
|
"@types/supertest": "6.0.3",
|
|
66
66
|
"@types/swagger-ui-express": "4.1.8",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"npm-check-updates": "16.7.10",
|
|
75
75
|
"replace": "1.2.2",
|
|
76
76
|
"standard-version": "9.5.0",
|
|
77
|
-
"ts-jest": "29.4.
|
|
77
|
+
"ts-jest": "29.4.3",
|
|
78
78
|
"ts-node": "10.9.2",
|
|
79
79
|
"typescript": "5.9.2"
|
|
80
80
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mojaloop/sdk-scheme-adapter-outbound-domain-event-handler",
|
|
3
|
-
"version": "0.3.0-snapshot.
|
|
3
|
+
"version": "0.3.0-snapshot.59",
|
|
4
4
|
"description": "mojaloop sdk scheme adapter outbound domain event handler",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://github.com/mojaloop/sdk-scheme-adapter/",
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
"@types/convict": "6.1.6",
|
|
58
58
|
"@types/express": "5.0.3",
|
|
59
59
|
"@types/jest": "30.0.0",
|
|
60
|
-
"@types/node": "24.5.
|
|
60
|
+
"@types/node": "24.5.2",
|
|
61
61
|
"@types/node-cache": "4.2.5",
|
|
62
62
|
"@types/supertest": "6.0.3",
|
|
63
63
|
"@types/swagger-ui-express": "4.1.8",
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
"npm-check-updates": "16.7.10",
|
|
72
72
|
"replace": "1.2.2",
|
|
73
73
|
"standard-version": "9.5.0",
|
|
74
|
-
"ts-jest": "29.4.
|
|
74
|
+
"ts-jest": "29.4.3",
|
|
75
75
|
"ts-node": "10.9.2",
|
|
76
76
|
"typescript": "5.9.2"
|
|
77
77
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mojaloop/sdk-scheme-adapter-private-shared-lib",
|
|
3
|
-
"version": "0.4.0-snapshot.
|
|
3
|
+
"version": "0.4.0-snapshot.59",
|
|
4
4
|
"description": "SDK Scheme Adapter private shared library.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://github.com/mojaloop/accounts-and-balances-bc/tree/main/modules/private-types",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@mojaloop/api-snippets": "18.1.1",
|
|
33
|
-
"@mojaloop/central-services-shared": "18.33.
|
|
33
|
+
"@mojaloop/central-services-shared": "18.33.2",
|
|
34
34
|
"@mojaloop/logging-bc-public-types-lib": "0.5.6",
|
|
35
35
|
"@mojaloop/platform-shared-lib-messaging-types-lib": "0.7.3",
|
|
36
36
|
"@mojaloop/platform-shared-lib-nodejs-kafka-client-lib": "0.5.18",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
42
|
"@eslint/compat": "1.3.2",
|
|
43
|
-
"@types/node": "24.5.
|
|
43
|
+
"@types/node": "24.5.2",
|
|
44
44
|
"@types/uuid": "10.0.0",
|
|
45
45
|
"@typescript-eslint/eslint-plugin": "8.44.0",
|
|
46
46
|
"@typescript-eslint/parser": "8.44.0",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"npm-check-updates": "16.7.10",
|
|
50
50
|
"replace": "1.2.2",
|
|
51
51
|
"standard-version": "9.5.0",
|
|
52
|
-
"ts-jest": "29.4.
|
|
52
|
+
"ts-jest": "29.4.3",
|
|
53
53
|
"tslib": "2.8.1",
|
|
54
54
|
"typescript": "5.9.2"
|
|
55
55
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mojaloop/sdk-scheme-adapter",
|
|
3
|
-
"version": "24.11.0-snapshot.
|
|
3
|
+
"version": "24.11.0-snapshot.5",
|
|
4
4
|
"description": "mojaloop sdk-scheme-adapter",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://github.com/mojaloop/sdk-scheme-adapter",
|
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
},
|
|
83
83
|
"devDependencies": {
|
|
84
84
|
"@types/jest": "30.0.0",
|
|
85
|
-
"@types/node": "24.5.
|
|
85
|
+
"@types/node": "24.5.2",
|
|
86
86
|
"@types/node-cache": "4.2.5",
|
|
87
87
|
"@typescript-eslint/eslint-plugin": "8.44.0",
|
|
88
88
|
"@typescript-eslint/parser": "8.44.0",
|
|
@@ -97,7 +97,7 @@
|
|
|
97
97
|
"npm-check-updates": "16.7.10",
|
|
98
98
|
"replace": "1.2.2",
|
|
99
99
|
"standard-version": "9.5.0",
|
|
100
|
-
"ts-jest": "29.4.
|
|
100
|
+
"ts-jest": "29.4.3",
|
|
101
101
|
"ts-node": "10.9.2",
|
|
102
102
|
"typescript": "5.9.2",
|
|
103
103
|
"yarn-audit-fix": "10.1.1"
|