@mcp-abap-adt/connection 25.0.1 → 25.2.0
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/CHANGELOG.md +104 -1
- package/README.md +97 -1
- package/dist/connection/AbstractAbapConnection.d.ts +12 -4
- package/dist/connection/AbstractAbapConnection.d.ts.map +1 -1
- package/dist/connection/AbstractAbapConnection.js +256 -81
- package/dist/connection/HttpTransport.d.ts +3 -1
- package/dist/connection/HttpTransport.d.ts.map +1 -1
- package/dist/connection/HttpTransport.js +76 -17
- package/dist/connection/IAdtTransport.d.ts +38 -1
- package/dist/connection/IAdtTransport.d.ts.map +1 -1
- package/dist/connection/RfcTransport.d.ts.map +1 -1
- package/dist/connection/RfcTransport.js +67 -24
- package/dist/connection/createConnection.d.ts.map +1 -1
- package/dist/connection/createConnection.js +6 -1
- package/dist/connection/csrfRetry.d.ts +10 -0
- package/dist/connection/csrfRetry.d.ts.map +1 -0
- package/dist/connection/csrfRetry.js +43 -0
- package/dist/connection/exactText.d.ts +43 -0
- package/dist/connection/exactText.d.ts.map +1 -0
- package/dist/connection/exactText.js +168 -0
- package/dist/connection/failureFacts.d.ts +3 -1
- package/dist/connection/failureFacts.d.ts.map +1 -1
- package/dist/connection/failureFacts.js +33 -3
- package/dist/connection/quietLine.d.ts +44 -0
- package/dist/connection/quietLine.d.ts.map +1 -0
- package/dist/connection/quietLine.js +113 -0
- package/dist/connection/statefulRequest.d.ts +13 -0
- package/dist/connection/statefulRequest.d.ts.map +1 -1
- package/dist/connection/statefulRequest.js +27 -1
- package/dist/connection/withCheckRelogon.d.ts +7 -1
- package/dist/connection/withCheckRelogon.d.ts.map +1 -1
- package/dist/connection/withCheckRelogon.js +18 -5
- package/docs/STATEFUL_SESSION_GUIDE.md +5 -1
- package/docs/USAGE.md +38 -2
- package/package.json +2 -2
|
@@ -1,4 +1,37 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
2
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
36
|
exports.AbstractAbapConnection = void 0;
|
|
4
37
|
exports.carriesSessionLost = carriesSessionLost;
|
|
@@ -8,8 +41,11 @@ const SessionLifecycle_js_1 = require("../session/SessionLifecycle.js");
|
|
|
8
41
|
const networkErrors_js_1 = require("../utils/networkErrors.js");
|
|
9
42
|
const authErrors_js_1 = require("./authErrors.js");
|
|
10
43
|
const csrfConfig_js_1 = require("./csrfConfig.js");
|
|
44
|
+
const csrfRetry = __importStar(require("./csrfRetry.js"));
|
|
45
|
+
const exactText_js_1 = require("./exactText.js");
|
|
11
46
|
const failureFacts_js_1 = require("./failureFacts.js");
|
|
12
47
|
const IAdtTransport_js_1 = require("./IAdtTransport.js");
|
|
48
|
+
const quietLine_js_1 = require("./quietLine.js");
|
|
13
49
|
const statefulRequest_js_1 = require("./statefulRequest.js");
|
|
14
50
|
/**
|
|
15
51
|
* Declares the capabilities explicitly rather than satisfying them by accident.
|
|
@@ -66,6 +102,21 @@ function dataPreview(data) {
|
|
|
66
102
|
return undefined;
|
|
67
103
|
}
|
|
68
104
|
}
|
|
105
|
+
/** A request's `noResend`, `noLog` and `rawText`, and nothing else of it. */
|
|
106
|
+
function flagsOf(request) {
|
|
107
|
+
return {
|
|
108
|
+
...(request.noResend ? { noResend: true } : {}),
|
|
109
|
+
...(request.noLog ? { noLog: true } : {}),
|
|
110
|
+
...(request.rawText ? { rawText: true } : {}),
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* What a `noResend` request resolves on: `2xx` as always, and a `3xx` from
|
|
115
|
+
* SAP's own endpoint, which is returned rather than followed.
|
|
116
|
+
*/
|
|
117
|
+
function admitsRedirects(status) {
|
|
118
|
+
return status >= 200 && status < 400;
|
|
119
|
+
}
|
|
69
120
|
/** Whether a thrown value is a refusal this connection marked `sessionLost`. */
|
|
70
121
|
function carriesSessionLost(error) {
|
|
71
122
|
return (typeof error === 'object' &&
|
|
@@ -665,6 +716,8 @@ class AbstractAbapConnection {
|
|
|
665
716
|
closing = Promise.reject(error);
|
|
666
717
|
}
|
|
667
718
|
const answered = closing.catch((error) => {
|
|
719
|
+
if (context.noLog)
|
|
720
|
+
return;
|
|
668
721
|
this.logger?.debug(`Could not tell the server the session is finished: ${(0, failureFacts_js_1.factWords)(error)}`);
|
|
669
722
|
});
|
|
670
723
|
// A close that is over is past its write: it sent nothing, it failed to
|
|
@@ -976,7 +1029,9 @@ class AbstractAbapConnection {
|
|
|
976
1029
|
* Does not await: it is called from inside a request, and the cleanup must not
|
|
977
1030
|
* wait for the very request that raised it.
|
|
978
1031
|
*/
|
|
979
|
-
raiseSessionLost(reason
|
|
1032
|
+
raiseSessionLost(reason,
|
|
1033
|
+
/** Lost by a `noLog` request's answer: the caller is told, nothing logged. */
|
|
1034
|
+
quiet = false) {
|
|
980
1035
|
// The instance's one session is gone: it is spent, as after disconnect().
|
|
981
1036
|
// Nothing else is decided here — the caller is told, and decides. The
|
|
982
1037
|
// verdict first, then the word: a logger that throws cannot undo it.
|
|
@@ -986,7 +1041,9 @@ class AbstractAbapConnection {
|
|
|
986
1041
|
this.clearSessionState();
|
|
987
1042
|
this.lifecycle.markDisconnected();
|
|
988
1043
|
});
|
|
989
|
-
|
|
1044
|
+
if (!quiet) {
|
|
1045
|
+
this.logQuietly(() => this.logger?.warn(`Session lost: ${reason}`));
|
|
1046
|
+
}
|
|
990
1047
|
}
|
|
991
1048
|
/**
|
|
992
1049
|
* A log line on a failure path: a logger that throws must not replace the
|
|
@@ -1032,7 +1089,9 @@ class AbstractAbapConnection {
|
|
|
1032
1089
|
* caller's — `'lost'` is returned instead of the throw. Not given for the
|
|
1033
1090
|
* connection's own exchanges and for stateful requests.
|
|
1034
1091
|
*/
|
|
1035
|
-
keepAnswer = false
|
|
1092
|
+
keepAnswer = false,
|
|
1093
|
+
/** The answer is a `noLog` request's: the wire logs nothing of it. */
|
|
1094
|
+
quiet = false) {
|
|
1036
1095
|
// Fenced by SESSION GENERATION, not by the teardown epoch. Only a
|
|
1037
1096
|
// caller-initiated teardown moves the epoch — a recovery deliberately does
|
|
1038
1097
|
// not — so after a session loss and a successful recovery, a request from
|
|
@@ -1044,13 +1103,19 @@ class AbstractAbapConnection {
|
|
|
1044
1103
|
// session this would compare against.
|
|
1045
1104
|
if (generation !== undefined &&
|
|
1046
1105
|
generation !== this.lifecycle.sessionGeneration) {
|
|
1047
|
-
|
|
1106
|
+
// `noLog`: the request's one line is its quiet one.
|
|
1107
|
+
if (!quiet) {
|
|
1108
|
+
this.logger?.debug('Ignoring a response from a previous session: its effects are fenced');
|
|
1109
|
+
}
|
|
1048
1110
|
return 'kept';
|
|
1049
1111
|
}
|
|
1050
1112
|
// The wire folds the response into its own state; what the change MEANS
|
|
1051
1113
|
// is decided here, because it is a question about the session's lifetime.
|
|
1052
|
-
|
|
1053
|
-
|
|
1114
|
+
if (quiet)
|
|
1115
|
+
this.transport.ingest(headers, { noLog: true });
|
|
1116
|
+
else
|
|
1117
|
+
this.transport.ingest(headers);
|
|
1118
|
+
return this.applyIdentityPolicy(this.lifecycle.observe(this.transport.sessionFingerprint()), keepAnswer, quiet);
|
|
1054
1119
|
}
|
|
1055
1120
|
/**
|
|
1056
1121
|
* Acts on what a response said about the session identity.
|
|
@@ -1068,7 +1133,9 @@ class AbstractAbapConnection {
|
|
|
1068
1133
|
* Being wrong in this direction costs a reconnect; being wrong the other way
|
|
1069
1134
|
* costs a lock nobody can find.
|
|
1070
1135
|
*/
|
|
1071
|
-
applyIdentityPolicy(classification, keepAnswer
|
|
1136
|
+
applyIdentityPolicy(classification, keepAnswer,
|
|
1137
|
+
/** A `noLog` request's answer: the loss and its logoff write no line. */
|
|
1138
|
+
quiet = false) {
|
|
1072
1139
|
if (classification !== 'replaced')
|
|
1073
1140
|
return 'kept';
|
|
1074
1141
|
// The answer that replaced the session brought a session of its own,
|
|
@@ -1086,9 +1153,9 @@ class AbstractAbapConnection {
|
|
|
1086
1153
|
// logoff: the wire took its snapshot synchronously, and any other path
|
|
1087
1154
|
// that would end the session — a failed `connect()`'s logoff above all —
|
|
1088
1155
|
// must find nothing left to send, or the same session is logged off twice.
|
|
1089
|
-
this.endSession(this.sessionContext());
|
|
1156
|
+
this.endSession(quiet ? { ...this.sessionContext(), noLog: true } : this.sessionContext());
|
|
1090
1157
|
this.clearSessionState();
|
|
1091
|
-
this.raiseSessionLost('the session cookie changed under us');
|
|
1158
|
+
this.raiseSessionLost('the session cookie changed under us', quiet);
|
|
1092
1159
|
// A stateless request's answer is SAP's, and valid: it is returned, marked,
|
|
1093
1160
|
// the session already lost (fr0ster/mcp-abap-adt#354). Nothing is sent
|
|
1094
1161
|
// again for it. A stateful request — the one a lock is taken and released
|
|
@@ -1206,10 +1273,21 @@ class AbstractAbapConnection {
|
|
|
1206
1273
|
// shut the door.
|
|
1207
1274
|
const lease = this.lifecycle.admitRequest();
|
|
1208
1275
|
try {
|
|
1209
|
-
|
|
1276
|
+
const response = await this.performRequest(options, lease);
|
|
1277
|
+
// `rawText`: the caller's view, and only the caller's — everything
|
|
1278
|
+
// inside has read the answer by now.
|
|
1279
|
+
if (options.rawText)
|
|
1280
|
+
(0, exactText_js_1.toCallerView)(response);
|
|
1281
|
+
return response;
|
|
1210
1282
|
}
|
|
1211
1283
|
catch (error) {
|
|
1212
|
-
|
|
1284
|
+
const outward = (0, authErrors_js_1.outwardLogonError)(error);
|
|
1285
|
+
if (options.rawText) {
|
|
1286
|
+
const refusal = (0, IAdtTransport_js_1.refusalOf)(outward);
|
|
1287
|
+
if (refusal)
|
|
1288
|
+
(0, exactText_js_1.toCallerView)(refusal);
|
|
1289
|
+
}
|
|
1290
|
+
throw outward;
|
|
1213
1291
|
}
|
|
1214
1292
|
finally {
|
|
1215
1293
|
lease.release();
|
|
@@ -1232,7 +1310,20 @@ class AbstractAbapConnection {
|
|
|
1232
1310
|
// exchange itself does not stop the request — the CSRF recovery below
|
|
1233
1311
|
// handles a token that is missing — but a refused credential does.
|
|
1234
1312
|
if (mutation && !this.transport.csrfToken()) {
|
|
1235
|
-
|
|
1313
|
+
try {
|
|
1314
|
+
await this.readyWireUpfront(renewal, lease, flagsOf(options));
|
|
1315
|
+
}
|
|
1316
|
+
catch (error) {
|
|
1317
|
+
// `noLog`: a request that ends before it is sent still writes its
|
|
1318
|
+
// one quiet line — the fetch's answer is the request's.
|
|
1319
|
+
if (options.noLog) {
|
|
1320
|
+
this.logQuietly(() => {
|
|
1321
|
+
const quiet = (0, quietLine_js_1.quietLine)(normalizedMethod, endpoint, (0, IAdtTransport_js_1.refusalOf)(error) ?? undefined);
|
|
1322
|
+
this.logger?.error(quiet.line, quiet.facts);
|
|
1323
|
+
});
|
|
1324
|
+
}
|
|
1325
|
+
throw error;
|
|
1326
|
+
}
|
|
1236
1327
|
}
|
|
1237
1328
|
// The request's own headers: everything but the credential's, which is
|
|
1238
1329
|
// written fresh onto a copy of these for every attempt (`authorizedFrom`).
|
|
@@ -1323,27 +1414,53 @@ class AbstractAbapConnection {
|
|
|
1323
1414
|
// `unknown` on the caller's options, a record on the seam: the two
|
|
1324
1415
|
// transports serialise a query differently and both need the pairs.
|
|
1325
1416
|
params: params,
|
|
1326
|
-
|
|
1417
|
+
// `stateless` wins over the session mode, for this request alone: the
|
|
1418
|
+
// mode itself is not touched, so the next ordinary request follows it.
|
|
1419
|
+
stateful: !options.stateless && this.sessionMode === 'stateful',
|
|
1420
|
+
...(options.stateless ? { stateless: true } : {}),
|
|
1421
|
+
// `noResend`: the wire sends it once and follows no redirect, and a
|
|
1422
|
+
// `3xx` from SAP's own endpoint is the caller's answer; every other
|
|
1423
|
+
// status keeps today's verdict.
|
|
1424
|
+
...(options.noResend
|
|
1425
|
+
? { noResend: true, validateStatus: admitsRedirects }
|
|
1426
|
+
: {}),
|
|
1427
|
+
// `noLog`: every line about this request, here and on the wire, is the
|
|
1428
|
+
// quiet one.
|
|
1429
|
+
...(options.noLog ? { noLog: true } : {}),
|
|
1430
|
+
// `rawText`: only the caller's view changes (`toCallerView`, at the
|
|
1431
|
+
// door); every resend below reuses requestConfig.
|
|
1432
|
+
...(options.rawText ? { rawText: true } : {}),
|
|
1327
1433
|
};
|
|
1328
1434
|
if (data !== undefined) {
|
|
1329
1435
|
requestConfig.data = data;
|
|
1330
1436
|
}
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1437
|
+
// `noLog`: nothing before the answer; the one line is written once there
|
|
1438
|
+
// is a status to put on it (`quietLine`).
|
|
1439
|
+
if (!options.noLog) {
|
|
1440
|
+
this.logger?.debug(`Executing ${normalizedMethod} request to: ${requestUrl}`, {
|
|
1441
|
+
type: 'REQUEST_INFO',
|
|
1442
|
+
url: requestUrl,
|
|
1443
|
+
method: normalizedMethod,
|
|
1444
|
+
});
|
|
1445
|
+
}
|
|
1336
1446
|
try {
|
|
1337
1447
|
const response = await this.sendObserved(requestConfig, lease);
|
|
1338
1448
|
// The answer outranks the logger's word on it: a logger that throws
|
|
1339
1449
|
// must not take a received answer — one marked `sessionLost` above all,
|
|
1340
1450
|
// whose session is already gone — from the caller.
|
|
1341
|
-
this.logQuietly(() =>
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1451
|
+
this.logQuietly(() => {
|
|
1452
|
+
if (options.noLog) {
|
|
1453
|
+
const quiet = (0, quietLine_js_1.quietLine)(normalizedMethod, requestUrl, response);
|
|
1454
|
+
this.logger?.debug(quiet.line, quiet.facts);
|
|
1455
|
+
return;
|
|
1456
|
+
}
|
|
1457
|
+
this.logger?.debug(`Request succeeded with status ${response.status}`, {
|
|
1458
|
+
type: 'REQUEST_SUCCESS',
|
|
1459
|
+
status: response.status,
|
|
1460
|
+
url: requestUrl,
|
|
1461
|
+
method: normalizedMethod,
|
|
1462
|
+
});
|
|
1463
|
+
});
|
|
1347
1464
|
return response;
|
|
1348
1465
|
}
|
|
1349
1466
|
catch (error) {
|
|
@@ -1371,13 +1488,18 @@ class AbstractAbapConnection {
|
|
|
1371
1488
|
throw (0, SessionLifecycle_js_1.sessionError)(interfaces_adt_connection_1.ADT_SESSION_ERROR.NOT_CONNECTED, 'The session this request was admitted to is gone; nothing was sent');
|
|
1372
1489
|
}
|
|
1373
1490
|
const response = await this.transport.send(requestConfig);
|
|
1374
|
-
const observed = this.observeResponse(response.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig));
|
|
1491
|
+
const observed = this.observeResponse(response.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig), requestConfig.noLog === true);
|
|
1375
1492
|
const answer = response;
|
|
1376
1493
|
// The answer itself says the session is gone: a field, on the one object
|
|
1377
1494
|
// that answers this request, never a word.
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1495
|
+
if (observed !== 'lost')
|
|
1496
|
+
return answer;
|
|
1497
|
+
const marked = {
|
|
1498
|
+
...answer,
|
|
1499
|
+
sessionLost: interfaces_adt_connection_1.ADT_SESSION_ERROR.SESSION_REPLACED,
|
|
1500
|
+
};
|
|
1501
|
+
(0, exactText_js_1.carryExact)(answer, marked);
|
|
1502
|
+
return marked;
|
|
1381
1503
|
}
|
|
1382
1504
|
/**
|
|
1383
1505
|
* SAP's refusal of a stateless request whose answer showed the session
|
|
@@ -1470,7 +1592,14 @@ class AbstractAbapConnection {
|
|
|
1470
1592
|
//
|
|
1471
1593
|
// A stale request gets its error back and nothing else happens.
|
|
1472
1594
|
if (!this.lifecycle.isCurrent(lease)) {
|
|
1473
|
-
this.logQuietly(() =>
|
|
1595
|
+
this.logQuietly(() => {
|
|
1596
|
+
if (requestConfig.noLog) {
|
|
1597
|
+
const fenced = (0, quietLine_js_1.quietLine)(normalizedMethod, requestUrl, (0, IAdtTransport_js_1.refusalOf)(error) ?? undefined);
|
|
1598
|
+
this.logger?.debug(fenced.line, fenced.facts);
|
|
1599
|
+
return;
|
|
1600
|
+
}
|
|
1601
|
+
this.logger?.debug('A request from a previous session failed; its recovery is fenced');
|
|
1602
|
+
});
|
|
1474
1603
|
throw error;
|
|
1475
1604
|
}
|
|
1476
1605
|
const errorDetails = {
|
|
@@ -1483,26 +1612,47 @@ class AbstractAbapConnection {
|
|
|
1483
1612
|
data: undefined,
|
|
1484
1613
|
};
|
|
1485
1614
|
const refusal = (0, IAdtTransport_js_1.refusalOf)(error);
|
|
1615
|
+
// `noLog`: the failure's lines carry the method, the path without its
|
|
1616
|
+
// query, the integer status and the byte count — no preview, no words.
|
|
1617
|
+
const quiet = requestConfig.noLog
|
|
1618
|
+
? (0, quietLine_js_1.quietLine)(normalizedMethod, requestUrl, refusal ?? undefined)
|
|
1619
|
+
: null;
|
|
1620
|
+
// Written here, once, before anything below can end the request — a
|
|
1621
|
+
// session verdict included, which then reaches the caller as the error
|
|
1622
|
+
// (`sessionLost`, `SESSION_REPLACED`) and never as a line.
|
|
1623
|
+
if (quiet) {
|
|
1624
|
+
this.logQuietly(() => {
|
|
1625
|
+
if (refusal?.status === 404)
|
|
1626
|
+
this.logger?.debug(quiet.line, quiet.facts);
|
|
1627
|
+
else
|
|
1628
|
+
this.logger?.error(quiet.line, quiet.facts);
|
|
1629
|
+
});
|
|
1630
|
+
}
|
|
1486
1631
|
if (refusal) {
|
|
1487
1632
|
errorDetails.data = dataPreview(refusal.data);
|
|
1488
1633
|
// Every wire's refusal, not only axios's. A response the connection
|
|
1489
1634
|
// never observed is a session replacement it never noticed. A stateless
|
|
1490
1635
|
// request's refusal that showed one is the caller's answer: no recovery
|
|
1491
1636
|
// starts from it — no CSRF retry, no credential renewal.
|
|
1492
|
-
const observed = this.observeResponse(refusal.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig));
|
|
1637
|
+
const observed = this.observeResponse(refusal.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig), requestConfig.noLog === true);
|
|
1493
1638
|
if (observed === 'lost')
|
|
1494
1639
|
throw this.markedLost(error);
|
|
1495
1640
|
}
|
|
1496
|
-
this.throwIfSessionDead(error, lease);
|
|
1641
|
+
this.throwIfSessionDead(error, lease, quiet !== null);
|
|
1497
1642
|
// Check if this is a network error (connection refused, timeout, DNS, etc.)
|
|
1498
1643
|
// Don't retry for network errors - these indicate infrastructure/VPN issues
|
|
1499
1644
|
const networkError = (0, networkErrors_js_1.isNetworkError)(error);
|
|
1500
1645
|
if (networkError) {
|
|
1501
|
-
|
|
1646
|
+
if (!quiet) {
|
|
1647
|
+
this.logQuietly(() => this.logger?.error(`Network error - cannot connect to SAP system: ${errorDetails.message}`, errorDetails));
|
|
1648
|
+
}
|
|
1502
1649
|
throw error;
|
|
1503
1650
|
}
|
|
1504
1651
|
// Log 404 as debug (common for existence checks), other errors as error
|
|
1505
|
-
if (
|
|
1652
|
+
if (quiet) {
|
|
1653
|
+
// Written above.
|
|
1654
|
+
}
|
|
1655
|
+
else if (errorDetails.status === 404) {
|
|
1506
1656
|
this.logQuietly(() => this.logger?.debug(errorDetails.message, errorDetails));
|
|
1507
1657
|
}
|
|
1508
1658
|
else {
|
|
@@ -1515,13 +1665,18 @@ class AbstractAbapConnection {
|
|
|
1515
1665
|
// A CSRF complaint (403 "CSRF token validation failed", or a 401 to a
|
|
1516
1666
|
// mutation that holds no token yet): a token earned in the SAME session —
|
|
1517
1667
|
// the cookies are kept — and one resend.
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1668
|
+
// `noResend`: the first failure is the caller's answer — an abapGit
|
|
1669
|
+
// handler's own 500 holding `CSRF token` would be resent after it ran.
|
|
1670
|
+
if (!requestConfig.noResend &&
|
|
1671
|
+
this.shouldRetryCsrf(error, normalizedMethod)) {
|
|
1672
|
+
if (!quiet) {
|
|
1673
|
+
this.logger?.debug('CSRF token validation failed, fetching new token and retrying request', {
|
|
1674
|
+
url: requestUrl,
|
|
1675
|
+
method: normalizedMethod,
|
|
1676
|
+
});
|
|
1677
|
+
}
|
|
1523
1678
|
try {
|
|
1524
|
-
this.setCsrfToken(await this.fetchCsrfToken(requestUrl, lease));
|
|
1679
|
+
this.setCsrfToken(await this.fetchCsrfToken(requestUrl, lease, flagsOf(requestConfig)));
|
|
1525
1680
|
const refreshedToken = this.getCsrfToken();
|
|
1526
1681
|
if (refreshedToken) {
|
|
1527
1682
|
requestHeaders['x-csrf-token'] = refreshedToken;
|
|
@@ -1544,11 +1699,11 @@ class AbstractAbapConnection {
|
|
|
1544
1699
|
// replacement it shows is its own answer, not the first attempt's 403.
|
|
1545
1700
|
const retryRefusal = (0, IAdtTransport_js_1.refusalOf)(retryError);
|
|
1546
1701
|
if (retryRefusal) {
|
|
1547
|
-
const observed = this.observeResponse(retryRefusal.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig));
|
|
1702
|
+
const observed = this.observeResponse(retryRefusal.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig), requestConfig.noLog === true);
|
|
1548
1703
|
if (observed === 'lost')
|
|
1549
1704
|
throw this.markedLost(retryError);
|
|
1550
1705
|
}
|
|
1551
|
-
this.throwIfSessionDead(retryError, lease);
|
|
1706
|
+
this.throwIfSessionDead(retryError, lease, quiet !== null);
|
|
1552
1707
|
// A session verdict outranks the error that started the retry: the
|
|
1553
1708
|
// caller can retry a 403 itself, but it cannot discover that its lock
|
|
1554
1709
|
// handle is dead from a 403. So does the credential's failure, which
|
|
@@ -1556,7 +1711,9 @@ class AbstractAbapConnection {
|
|
|
1556
1711
|
if (this.outranksOriginal(retryError)) {
|
|
1557
1712
|
throw retryError;
|
|
1558
1713
|
}
|
|
1559
|
-
|
|
1714
|
+
if (!quiet) {
|
|
1715
|
+
this.logQuietly(() => this.logger?.debug(`CSRF retry failed; rethrowing original error: ${(0, failureFacts_js_1.factWords)(retryError)}`));
|
|
1716
|
+
}
|
|
1560
1717
|
throw error;
|
|
1561
1718
|
}
|
|
1562
1719
|
}
|
|
@@ -1580,7 +1737,11 @@ class AbstractAbapConnection {
|
|
|
1580
1737
|
if (this.isSessionVerdict(failure))
|
|
1581
1738
|
throw failure;
|
|
1582
1739
|
// A resend inside the wire's recovery that met a dead session.
|
|
1583
|
-
this.throwIfSessionDead(failure, lease);
|
|
1740
|
+
this.throwIfSessionDead(failure, lease, requestConfig.noLog === true);
|
|
1741
|
+
// `noResend`: nothing to renew for, since nothing is resent — the refusal
|
|
1742
|
+
// is the caller's answer, and the provider is not asked.
|
|
1743
|
+
if (requestConfig.noResend)
|
|
1744
|
+
throw failure;
|
|
1584
1745
|
const rejection = this.credentialRejection(failure);
|
|
1585
1746
|
// A request from a previous session asks nobody anything: its recovery is
|
|
1586
1747
|
// fenced, and so is the credential's.
|
|
@@ -1596,7 +1757,7 @@ class AbstractAbapConnection {
|
|
|
1596
1757
|
try {
|
|
1597
1758
|
if (rejection.at === 'logon') {
|
|
1598
1759
|
this.transport.adoptCsrfToken(null);
|
|
1599
|
-
await this.ensureWireReady(lease);
|
|
1760
|
+
await this.ensureWireReady(lease, flagsOf(requestConfig));
|
|
1600
1761
|
const token = this.transport.csrfToken();
|
|
1601
1762
|
if (token && ['POST', 'PUT', 'DELETE'].includes(requestConfig.method)) {
|
|
1602
1763
|
requestHeaders['x-csrf-token'] = token;
|
|
@@ -1622,11 +1783,11 @@ class AbstractAbapConnection {
|
|
|
1622
1783
|
// SAP replaced in between is SESSION_REPLACED, not a bare status.
|
|
1623
1784
|
const refusal = (0, IAdtTransport_js_1.refusalOf)(again);
|
|
1624
1785
|
if (refusal) {
|
|
1625
|
-
const observed = this.observeResponse(refusal.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig));
|
|
1786
|
+
const observed = this.observeResponse(refusal.headers, lease.generation, !(0, statefulRequest_js_1.isStatefulRequest)(requestConfig), requestConfig.noLog === true);
|
|
1626
1787
|
if (observed === 'lost')
|
|
1627
1788
|
throw this.markedLost(again);
|
|
1628
1789
|
}
|
|
1629
|
-
this.throwIfSessionDead(again, lease);
|
|
1790
|
+
this.throwIfSessionDead(again, lease, requestConfig.noLog === true);
|
|
1630
1791
|
const secondRejection = this.credentialRejection(again);
|
|
1631
1792
|
if (!secondRejection)
|
|
1632
1793
|
throw again;
|
|
@@ -1643,15 +1804,17 @@ class AbstractAbapConnection {
|
|
|
1643
1804
|
* dead session. A request from a previous session says nothing about the
|
|
1644
1805
|
* current one, so its answer is not acted on.
|
|
1645
1806
|
*/
|
|
1646
|
-
throwIfSessionDead(error, lease
|
|
1807
|
+
throwIfSessionDead(error, lease,
|
|
1808
|
+
/** A `noLog` request's: the loss reaches the caller, no line. */
|
|
1809
|
+
quiet = false) {
|
|
1647
1810
|
if (error instanceof authErrors_js_1.WireSessionLostError) {
|
|
1648
|
-
this.throwWireSessionLost(error, lease);
|
|
1811
|
+
this.throwWireSessionLost(error, lease, quiet);
|
|
1649
1812
|
}
|
|
1650
1813
|
if (!this.isDeadSessionResponse(error))
|
|
1651
1814
|
return;
|
|
1652
1815
|
if (!this.lifecycle.isCurrent(lease))
|
|
1653
1816
|
return;
|
|
1654
|
-
this.raiseSessionLost('the server reports the session no longer exists');
|
|
1817
|
+
this.raiseSessionLost('the server reports the session no longer exists', quiet);
|
|
1655
1818
|
// No internal retry: a blind retry here is what produced further locks
|
|
1656
1819
|
// in the field. The caller decides.
|
|
1657
1820
|
throw (0, SessionLifecycle_js_1.sessionError)(interfaces_adt_connection_1.ADT_SESSION_ERROR.SESSION_REPLACED, 'The SAP session no longer exists; any lock handle from it is dead');
|
|
@@ -1664,10 +1827,10 @@ class AbstractAbapConnection {
|
|
|
1664
1827
|
* session: that is a new instance, the caller's to create. A mark from a
|
|
1665
1828
|
* previous session says nothing about the current one and is not acted on.
|
|
1666
1829
|
*/
|
|
1667
|
-
throwWireSessionLost(error, lease) {
|
|
1830
|
+
throwWireSessionLost(error, lease, quiet = false) {
|
|
1668
1831
|
if (!this.lifecycle.isCurrent(lease))
|
|
1669
1832
|
return;
|
|
1670
|
-
this.raiseSessionLost('the wire reports the session ended');
|
|
1833
|
+
this.raiseSessionLost('the wire reports the session ended', quiet);
|
|
1671
1834
|
const verdict = (0, SessionLifecycle_js_1.sessionError)(interfaces_adt_connection_1.ADT_SESSION_ERROR.SESSION_REPLACED, "The RFC conversation that carried this connection's SAP session has ended; any lock held in it is gone. Create a new connection for a new session.");
|
|
1672
1835
|
throw error.rfc === undefined
|
|
1673
1836
|
? verdict
|
|
@@ -1745,10 +1908,16 @@ class AbstractAbapConnection {
|
|
|
1745
1908
|
* fetch within the request's one retry — unless the session the request
|
|
1746
1909
|
* was admitted to is gone by then, when nothing more is sent.
|
|
1747
1910
|
*/
|
|
1748
|
-
async readyWireUpfront(renewal, lease
|
|
1911
|
+
async readyWireUpfront(renewal, lease,
|
|
1912
|
+
/**
|
|
1913
|
+
* The request's flags. `noResend`: the fetch goes once, and its failure —
|
|
1914
|
+
* a refused logon included, the provider not asked — is the request's
|
|
1915
|
+
* answer: the request is not sent. `noLog`: no line of the fetch's own.
|
|
1916
|
+
*/
|
|
1917
|
+
flags = {}) {
|
|
1749
1918
|
for (;;) {
|
|
1750
1919
|
try {
|
|
1751
|
-
await this.ensureWireReady(lease);
|
|
1920
|
+
await this.ensureWireReady(lease, flags);
|
|
1752
1921
|
return;
|
|
1753
1922
|
}
|
|
1754
1923
|
catch (error) {
|
|
@@ -1760,8 +1929,20 @@ class AbstractAbapConnection {
|
|
|
1760
1929
|
throw this.staleVerdict(error);
|
|
1761
1930
|
if (error instanceof authErrors_js_1.AuthRefusedError)
|
|
1762
1931
|
throw error;
|
|
1932
|
+
// `noResend`: the fetch's failure is the answer. A refused logon goes
|
|
1933
|
+
// as SAP's refusal it wraps — its status and body on top, as any
|
|
1934
|
+
// refusal's — since no provider is asked to act on the mark.
|
|
1935
|
+
if (flags.noResend) {
|
|
1936
|
+
throw error instanceof authErrors_js_1.WireLogonError && (0, IAdtTransport_js_1.refusalOf)(error.cause)
|
|
1937
|
+
? // A copy, made as every failure that leaves is: SAP's answer and
|
|
1938
|
+
// the facts, nothing of the request a custom wire put beside it.
|
|
1939
|
+
(0, failureFacts_js_1.failureCopy)(error.cause)
|
|
1940
|
+
: error;
|
|
1941
|
+
}
|
|
1763
1942
|
if (!(error instanceof authErrors_js_1.WireLogonError)) {
|
|
1764
|
-
|
|
1943
|
+
if (!flags.noLog) {
|
|
1944
|
+
this.logger?.debug(`Could not fetch CSRF token upfront, will retry on error: ${(0, failureFacts_js_1.factWords)(error)}`);
|
|
1945
|
+
}
|
|
1765
1946
|
return;
|
|
1766
1947
|
}
|
|
1767
1948
|
const rejection = this.credentialRejection(error);
|
|
@@ -1792,15 +1973,17 @@ class AbstractAbapConnection {
|
|
|
1792
1973
|
* wire's own ingest of it, and never stops the request being sent.
|
|
1793
1974
|
* Omitted during connect(), which has no lease.
|
|
1794
1975
|
*/
|
|
1795
|
-
fence
|
|
1976
|
+
fence,
|
|
1977
|
+
/** The flags of the request the token is fetched for. */
|
|
1978
|
+
flags = {}) {
|
|
1796
1979
|
// Dropped first, because this is only ever reached to REPLACE one: the
|
|
1797
1980
|
// establishment is idempotent and would hand back the very token the
|
|
1798
1981
|
// caller has just been told is stale.
|
|
1799
1982
|
this.transport.adoptCsrfToken(null);
|
|
1800
1983
|
await this.transport.establish({
|
|
1801
1984
|
...(typeof fence === 'number'
|
|
1802
|
-
? this.leasedContext(undefined, fence)
|
|
1803
|
-
: this.leasedContext(fence)),
|
|
1985
|
+
? this.leasedContext(undefined, fence, flags)
|
|
1986
|
+
: this.leasedContext(fence, undefined, flags)),
|
|
1804
1987
|
});
|
|
1805
1988
|
const token = this.transport.csrfToken();
|
|
1806
1989
|
if (!token)
|
|
@@ -1847,8 +2030,10 @@ class AbstractAbapConnection {
|
|
|
1847
2030
|
*/
|
|
1848
2031
|
async ensureWireReady(
|
|
1849
2032
|
/** The request's lease: fences what is sent and the response effects. */
|
|
1850
|
-
lease
|
|
1851
|
-
|
|
2033
|
+
lease,
|
|
2034
|
+
/** The flags of the request the wire is made ready for. */
|
|
2035
|
+
flags = {}) {
|
|
2036
|
+
await this.transport.establish(this.leasedContext(lease, undefined, flags));
|
|
1852
2037
|
}
|
|
1853
2038
|
/**
|
|
1854
2039
|
* The context for a token exchange a request makes on its own behalf — its
|
|
@@ -1866,8 +2051,14 @@ class AbstractAbapConnection {
|
|
|
1866
2051
|
* what the connection does with an answer, and nothing else: the request is
|
|
1867
2052
|
* sent, and the wire still folds the answer into its jar.
|
|
1868
2053
|
*/
|
|
1869
|
-
leasedContext(lease, generation = lease?.generation
|
|
2054
|
+
leasedContext(lease, generation = lease?.generation,
|
|
2055
|
+
/** The flags of the request the exchange is made for. */
|
|
2056
|
+
flags = {}) {
|
|
2057
|
+
const quiet = flags.noLog === true;
|
|
1870
2058
|
return {
|
|
2059
|
+
...(flags.noResend ? { noResend: true } : {}),
|
|
2060
|
+
...(quiet ? { noLog: true } : {}),
|
|
2061
|
+
...(flags.rawText ? { rawText: true } : {}),
|
|
1871
2062
|
authorize: async (headers) => {
|
|
1872
2063
|
await this.credentialHeaders(headers);
|
|
1873
2064
|
if (lease && !this.lifecycle.isCurrent(lease)) {
|
|
@@ -1884,7 +2075,7 @@ class AbstractAbapConnection {
|
|
|
1884
2075
|
if (lease && !this.lifecycle.isCurrent(lease)) {
|
|
1885
2076
|
throw (0, SessionLifecycle_js_1.sessionError)(interfaces_adt_connection_1.ADT_SESSION_ERROR.NOT_CONNECTED, 'The session this request was admitted to is gone; its answer was not taken');
|
|
1886
2077
|
}
|
|
1887
|
-
this.observeResponse(headers, generation);
|
|
2078
|
+
this.observeResponse(headers, generation, false, quiet);
|
|
1888
2079
|
},
|
|
1889
2080
|
};
|
|
1890
2081
|
}
|
|
@@ -1914,26 +2105,10 @@ class AbstractAbapConnection {
|
|
|
1914
2105
|
this.lifecycle.forgetIdentity();
|
|
1915
2106
|
}
|
|
1916
2107
|
shouldRetryCsrf(error, method) {
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
const responseData = refusal.data;
|
|
1922
|
-
const responseText = typeof responseData === 'string'
|
|
1923
|
-
? responseData
|
|
1924
|
-
: JSON.stringify(responseData || '');
|
|
1925
|
-
// Retry on 403 with CSRF message, or if response mentions CSRF token
|
|
1926
|
-
// Also retry on 401 for POST/PUT/DELETE if we don't have CSRF token yet (might need to get cookies first)
|
|
1927
|
-
// Handed in rather than read off `error.config`, which is axios's own
|
|
1928
|
-
// record of the request and does not exist on another wire's refusal. The
|
|
1929
|
-
// caller already normalised the method; asking the error for it was asking
|
|
1930
|
-
// the HTTP client.
|
|
1931
|
-
const normalized = method?.toUpperCase();
|
|
1932
|
-
const isPostPutDelete = normalized && ['POST', 'PUT', 'DELETE'].includes(normalized);
|
|
1933
|
-
const needsCsrfToken = !!isPostPutDelete && !this.transport.csrfToken();
|
|
1934
|
-
return ((refusal.status === 403 && responseText.includes('CSRF')) ||
|
|
1935
|
-
responseText.includes('CSRF token') ||
|
|
1936
|
-
(needsCsrfToken && refusal.status === 401));
|
|
2108
|
+
// Asked through its module: the order it is asked in is observable.
|
|
2109
|
+
return csrfRetry.shouldRetryCsrf(error, method,
|
|
2110
|
+
// Read only where the predicate always read it.
|
|
2111
|
+
() => this.transport.csrfToken());
|
|
1937
2112
|
}
|
|
1938
2113
|
}
|
|
1939
2114
|
exports.AbstractAbapConnection = AbstractAbapConnection;
|
|
@@ -133,7 +133,9 @@ export declare class HttpTransport implements IAdtTransport {
|
|
|
133
133
|
* establishment or a replacement is a question about the session's lifetime,
|
|
134
134
|
* which this has no way to answer and no business answering.
|
|
135
135
|
*/
|
|
136
|
-
ingest(headers?: Record<string, unknown
|
|
136
|
+
ingest(headers?: Record<string, unknown>, options?: {
|
|
137
|
+
noLog?: true | undefined;
|
|
138
|
+
}): void;
|
|
137
139
|
/** What to put on the `Cookie` header, or nothing if the jar is empty. */
|
|
138
140
|
cookies(): string | null;
|
|
139
141
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HttpTransport.d.ts","sourceRoot":"","sources":["../../src/connection/HttpTransport.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAIH,OAAO,EACL,KAAK,aAAa,EAClB,KAAK,IAAI,SAAS,EAGlB,KAAK,eAAe,EACpB,KAAK,cAAc,EACpB,MAAM,WAAW,CAAC;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