@mojaloop/sdk-scheme-adapter 24.11.0-snapshot.0 → 24.11.0-snapshot.2
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/modules/api-svc/package.json +1 -1
- package/modules/api-svc/src/lib/model/InboundTransfersModel.js +12 -11
- package/modules/outbound-command-event-handler/package.json +1 -1
- package/modules/outbound-domain-event-handler/package.json +1 -1
- package/modules/private-shared-lib/package.json +1 -1
- package/package.json +1 -1
|
@@ -504,6 +504,7 @@ class InboundTransfersModel {
|
|
|
504
504
|
|
|
505
505
|
setTimeout(async () => {
|
|
506
506
|
try {
|
|
507
|
+
this._logger.isInfoEnabled && this._logger.push({ transferId }).info('Patch notification grace time expired, attempting GET /transfers/{ID}');
|
|
507
508
|
const notified = await this._cache.get(cacheKey);
|
|
508
509
|
|
|
509
510
|
if (!notified) {
|
|
@@ -529,7 +530,7 @@ class InboundTransfersModel {
|
|
|
529
530
|
// Mark as notified to prevent duplicate notification
|
|
530
531
|
await this._cache.set(cacheKey, true, 60);
|
|
531
532
|
// Send notification to payee
|
|
532
|
-
await this.sendNotificationToPayee(message.data, transferId);
|
|
533
|
+
await this.sendNotificationToPayee(message.data.body, transferId);
|
|
533
534
|
break;
|
|
534
535
|
}
|
|
535
536
|
} catch (err) {
|
|
@@ -1056,11 +1057,11 @@ class InboundTransfersModel {
|
|
|
1056
1057
|
operation.attempt(async (currentAttempt) => {
|
|
1057
1058
|
try {
|
|
1058
1059
|
res = await this._backendRequests.putFxTransfersNotification(responseBody, conversionId);
|
|
1059
|
-
if (
|
|
1060
|
+
if (res) {
|
|
1060
1061
|
return resolve();
|
|
1061
1062
|
}
|
|
1062
|
-
log.warn(`putFxTransfersNotification attempt ${currentAttempt}
|
|
1063
|
-
if (!operation.retry(new Error('
|
|
1063
|
+
log.warn(`putFxTransfersNotification attempt ${currentAttempt} got no response, retrying...`);
|
|
1064
|
+
if (!operation.retry(new Error('No response'))) {
|
|
1064
1065
|
resolve();
|
|
1065
1066
|
}
|
|
1066
1067
|
} catch (err) {
|
|
@@ -1072,12 +1073,12 @@ class InboundTransfersModel {
|
|
|
1072
1073
|
});
|
|
1073
1074
|
});
|
|
1074
1075
|
|
|
1075
|
-
if (
|
|
1076
|
+
if (!res) {
|
|
1076
1077
|
log.error(`putFxTransfersNotification failed after ${operation.attempts()} attempts`);
|
|
1077
1078
|
}
|
|
1078
1079
|
} else {
|
|
1079
1080
|
res = await this._backendRequests.putFxTransfersNotification(responseBody, conversionId);
|
|
1080
|
-
if (
|
|
1081
|
+
if (!res) {
|
|
1081
1082
|
log.error('putFxTransfersNotification failed');
|
|
1082
1083
|
}
|
|
1083
1084
|
}
|
|
@@ -1139,13 +1140,13 @@ class InboundTransfersModel {
|
|
|
1139
1140
|
operation.attempt(async (currentAttempt) => {
|
|
1140
1141
|
try {
|
|
1141
1142
|
res = await this._backendRequests.putTransfersNotification(this.data, transferId);
|
|
1142
|
-
if (
|
|
1143
|
+
if (res) {
|
|
1143
1144
|
const cacheKey = `patchNotificationSent_${transferId}`;
|
|
1144
1145
|
await this._cache.set(cacheKey, true, 60);
|
|
1145
1146
|
return resolve();
|
|
1146
1147
|
}
|
|
1147
|
-
this._logger.warn(`putTransfersNotification attempt ${currentAttempt}
|
|
1148
|
-
if (!operation.retry(new Error('
|
|
1148
|
+
this._logger.warn(`putTransfersNotification attempt ${currentAttempt} got no response, retrying...`);
|
|
1149
|
+
if (!operation.retry(new Error('No response'))) {
|
|
1149
1150
|
resolve();
|
|
1150
1151
|
}
|
|
1151
1152
|
} catch (err) {
|
|
@@ -1157,12 +1158,12 @@ class InboundTransfersModel {
|
|
|
1157
1158
|
});
|
|
1158
1159
|
});
|
|
1159
1160
|
|
|
1160
|
-
if (
|
|
1161
|
+
if (!res) {
|
|
1161
1162
|
this._logger.error(`putTransfersNotification failed after ${operation.attempts()} attempts`);
|
|
1162
1163
|
}
|
|
1163
1164
|
} else {
|
|
1164
1165
|
res = await this._backendRequests.putTransfersNotification(this.data, transferId);
|
|
1165
|
-
if (
|
|
1166
|
+
if (!res) {
|
|
1166
1167
|
this._logger.error('putTransfersNotification failed');
|
|
1167
1168
|
}
|
|
1168
1169
|
}
|
|
@@ -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.56",
|
|
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/",
|
|
@@ -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.56",
|
|
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/",
|
|
@@ -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.56",
|
|
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",
|
package/package.json
CHANGED