@jsii/runtime 1.86.0 → 1.87.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/package.json +7 -7
- package/webpack/lib/program.js +124 -68
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jsii/runtime",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.87.0",
|
|
4
4
|
"description": "jsii runtime kernel process",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": {
|
|
@@ -34,14 +34,14 @@
|
|
|
34
34
|
"package": "package-js"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@jsii/kernel": "^1.
|
|
38
|
-
"@jsii/check-node": "1.
|
|
39
|
-
"@jsii/spec": "^1.
|
|
37
|
+
"@jsii/kernel": "^1.87.0",
|
|
38
|
+
"@jsii/check-node": "1.87.0",
|
|
39
|
+
"@jsii/spec": "^1.87.0"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@scope/jsii-calc-base": "^1.
|
|
43
|
-
"@scope/jsii-calc-lib": "^1.
|
|
44
|
-
"jsii-build-tools": "^1.
|
|
42
|
+
"@scope/jsii-calc-base": "^1.87.0",
|
|
43
|
+
"@scope/jsii-calc-lib": "^1.87.0",
|
|
44
|
+
"jsii-build-tools": "^1.87.0",
|
|
45
45
|
"jsii-calc": "^3.20.120",
|
|
46
46
|
"source-map-loader": "^4.0.1",
|
|
47
47
|
"webpack": "^5.88.2",
|
package/webpack/lib/program.js
CHANGED
|
@@ -9328,7 +9328,7 @@ var __webpack_modules__ = {
|
|
|
9328
9328
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
9329
9329
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
9330
9330
|
};
|
|
9331
|
-
var _DiskCache_instances, _a, _DiskCache_CACHE, _DiskCache_root, _DiskCache_entries, _Entry_instances, _Entry_lockFile_get, _Entry_markerFile_get;
|
|
9331
|
+
var _DiskCache_instances, _a, _DiskCache_CACHE, _DiskCache_root, _DiskCache_entries, _Entry_instances, _Entry_lockFile_get, _Entry_markerFile_get, _Entry_touchMarkerFile;
|
|
9332
9332
|
Object.defineProperty(exports, "__esModule", {
|
|
9333
9333
|
value: true
|
|
9334
9334
|
});
|
|
@@ -9440,13 +9440,49 @@ var __webpack_modules__ = {
|
|
|
9440
9440
|
get pathExists() {
|
|
9441
9441
|
return (0, fs_1.existsSync)(this.path);
|
|
9442
9442
|
}
|
|
9443
|
+
get isComplete() {
|
|
9444
|
+
return (0, fs_1.existsSync)(__classPrivateFieldGet(this, _Entry_instances, "a", _Entry_markerFile_get));
|
|
9445
|
+
}
|
|
9446
|
+
retrieve(cb) {
|
|
9447
|
+
if (this.isComplete) {
|
|
9448
|
+
__classPrivateFieldGet(this, _Entry_instances, "m", _Entry_touchMarkerFile).call(this);
|
|
9449
|
+
return {
|
|
9450
|
+
path: this.path,
|
|
9451
|
+
cache: "hit"
|
|
9452
|
+
};
|
|
9453
|
+
}
|
|
9454
|
+
let cache = "miss";
|
|
9455
|
+
this.lock((lock => {
|
|
9456
|
+
if (this.isComplete) {
|
|
9457
|
+
cache = "hit";
|
|
9458
|
+
return;
|
|
9459
|
+
}
|
|
9460
|
+
(0, fs_1.mkdirSync)(this.path, {
|
|
9461
|
+
recursive: true
|
|
9462
|
+
});
|
|
9463
|
+
try {
|
|
9464
|
+
cb(this.path);
|
|
9465
|
+
} catch (error) {
|
|
9466
|
+
(0, fs_1.rmSync)(this.path, {
|
|
9467
|
+
force: true,
|
|
9468
|
+
recursive: true
|
|
9469
|
+
});
|
|
9470
|
+
throw error;
|
|
9471
|
+
}
|
|
9472
|
+
lock.markComplete();
|
|
9473
|
+
}));
|
|
9474
|
+
return {
|
|
9475
|
+
path: this.path,
|
|
9476
|
+
cache
|
|
9477
|
+
};
|
|
9478
|
+
}
|
|
9443
9479
|
lock(cb) {
|
|
9444
9480
|
(0, fs_1.mkdirSync)((0, path_1.dirname)(this.path), {
|
|
9445
9481
|
recursive: true
|
|
9446
9482
|
});
|
|
9447
|
-
(
|
|
9483
|
+
lockSyncWithWait(__classPrivateFieldGet(this, _Entry_instances, "a", _Entry_lockFile_get), {
|
|
9448
9484
|
retries: 12,
|
|
9449
|
-
stale:
|
|
9485
|
+
stale: 1e4
|
|
9450
9486
|
});
|
|
9451
9487
|
let disposed = false;
|
|
9452
9488
|
try {
|
|
@@ -9469,18 +9505,11 @@ var __webpack_modules__ = {
|
|
|
9469
9505
|
});
|
|
9470
9506
|
(0, fs_1.writeFileSync)((0, path_1.join)(this.path, name), content);
|
|
9471
9507
|
},
|
|
9472
|
-
|
|
9508
|
+
markComplete: () => {
|
|
9473
9509
|
if (disposed) {
|
|
9474
9510
|
throw new Error(`Cannot touch ${this.path} once the lock block was returned!`);
|
|
9475
9511
|
}
|
|
9476
|
-
|
|
9477
|
-
if ((0, fs_1.existsSync)(__classPrivateFieldGet(this, _Entry_instances, "a", _Entry_markerFile_get))) {
|
|
9478
|
-
const now = new Date;
|
|
9479
|
-
(0, fs_1.utimesSync)(__classPrivateFieldGet(this, _Entry_instances, "a", _Entry_markerFile_get), now, now);
|
|
9480
|
-
} else {
|
|
9481
|
-
(0, fs_1.writeFileSync)(__classPrivateFieldGet(this, _Entry_instances, "a", _Entry_markerFile_get), "");
|
|
9482
|
-
}
|
|
9483
|
-
}
|
|
9512
|
+
__classPrivateFieldGet(this, _Entry_instances, "m", _Entry_touchMarkerFile).call(this);
|
|
9484
9513
|
}
|
|
9485
9514
|
});
|
|
9486
9515
|
} finally {
|
|
@@ -9504,6 +9533,18 @@ var __webpack_modules__ = {
|
|
|
9504
9533
|
return `${this.path}.lock`;
|
|
9505
9534
|
}, _Entry_markerFile_get = function _Entry_markerFile_get() {
|
|
9506
9535
|
return (0, path_1.join)(this.path, MARKER_FILE_NAME);
|
|
9536
|
+
}, _Entry_touchMarkerFile = function _Entry_touchMarkerFile() {
|
|
9537
|
+
if (this.pathExists) {
|
|
9538
|
+
try {
|
|
9539
|
+
const now = new Date;
|
|
9540
|
+
(0, fs_1.utimesSync)(__classPrivateFieldGet(this, _Entry_instances, "a", _Entry_markerFile_get), now, now);
|
|
9541
|
+
} catch (e) {
|
|
9542
|
+
if (e.code !== "ENOENT") {
|
|
9543
|
+
throw e;
|
|
9544
|
+
}
|
|
9545
|
+
(0, fs_1.writeFileSync)(__classPrivateFieldGet(this, _Entry_instances, "a", _Entry_markerFile_get), "");
|
|
9546
|
+
}
|
|
9547
|
+
}
|
|
9507
9548
|
};
|
|
9508
9549
|
function* directoriesUnder(root, recursive = false, ignoreErrors = true) {
|
|
9509
9550
|
for (const file of (0, fs_1.readdirSync)(root)) {
|
|
@@ -9523,6 +9564,34 @@ var __webpack_modules__ = {
|
|
|
9523
9564
|
}
|
|
9524
9565
|
}
|
|
9525
9566
|
}
|
|
9567
|
+
function lockSyncWithWait(path, options) {
|
|
9568
|
+
var _b;
|
|
9569
|
+
let retries = (_b = options.retries) !== null && _b !== void 0 ? _b : 0;
|
|
9570
|
+
let sleep = 100;
|
|
9571
|
+
while (true) {
|
|
9572
|
+
try {
|
|
9573
|
+
(0, lockfile_1.lockSync)(path, {
|
|
9574
|
+
retries: 0,
|
|
9575
|
+
stale: options.stale
|
|
9576
|
+
});
|
|
9577
|
+
return;
|
|
9578
|
+
} catch (e) {
|
|
9579
|
+
if (retries === 0) {
|
|
9580
|
+
throw e;
|
|
9581
|
+
}
|
|
9582
|
+
retries--;
|
|
9583
|
+
if (e.code === "EEXIST") {
|
|
9584
|
+
sleepSync(Math.floor(Math.random() * sleep));
|
|
9585
|
+
sleep *= 1.5;
|
|
9586
|
+
} else {
|
|
9587
|
+
sleepSync(5);
|
|
9588
|
+
}
|
|
9589
|
+
}
|
|
9590
|
+
}
|
|
9591
|
+
}
|
|
9592
|
+
function sleepSync(ms) {
|
|
9593
|
+
Atomics.wait(new Int32Array(new SharedArrayBuffer(4)), 0, 0, ms);
|
|
9594
|
+
}
|
|
9526
9595
|
},
|
|
9527
9596
|
7202: function(__unused_webpack_module, exports, __webpack_require__) {
|
|
9528
9597
|
"use strict";
|
|
@@ -10435,30 +10504,41 @@ var __webpack_modules__ = {
|
|
|
10435
10504
|
});
|
|
10436
10505
|
exports.link = void 0;
|
|
10437
10506
|
const fs_1 = __webpack_require__(7147);
|
|
10507
|
+
const os = __webpack_require__(2037);
|
|
10438
10508
|
const path_1 = __webpack_require__(4822);
|
|
10439
10509
|
const PRESERVE_SYMLINKS = process.execArgv.includes("--preserve-symlinks");
|
|
10440
|
-
function link(
|
|
10510
|
+
function link(existingRoot, destinationRoot) {
|
|
10511
|
+
(0, fs_1.mkdirSync)((0, path_1.dirname)(destinationRoot), {
|
|
10512
|
+
recursive: true
|
|
10513
|
+
});
|
|
10441
10514
|
if (PRESERVE_SYMLINKS) {
|
|
10442
|
-
(0, fs_1.mkdirSync)((0, path_1.dirname)(destination), {
|
|
10443
|
-
recursive: true
|
|
10444
|
-
});
|
|
10445
|
-
(0, fs_1.symlinkSync)(existing, destination);
|
|
10446
|
-
return;
|
|
10447
|
-
}
|
|
10448
|
-
const stat = (0, fs_1.statSync)(existing);
|
|
10449
|
-
if (!stat.isDirectory()) {
|
|
10450
10515
|
try {
|
|
10451
|
-
(0, fs_1.
|
|
10452
|
-
|
|
10453
|
-
|
|
10516
|
+
(0, fs_1.symlinkSync)(existingRoot, destinationRoot);
|
|
10517
|
+
return;
|
|
10518
|
+
} catch (e) {
|
|
10519
|
+
const winNoSymlink = e.code === "EPERM" && os.platform() === "win32";
|
|
10520
|
+
if (!winNoSymlink) {
|
|
10521
|
+
throw e;
|
|
10522
|
+
}
|
|
10454
10523
|
}
|
|
10455
|
-
return;
|
|
10456
10524
|
}
|
|
10457
|
-
(
|
|
10458
|
-
|
|
10459
|
-
|
|
10460
|
-
|
|
10461
|
-
|
|
10525
|
+
recurse(existingRoot, destinationRoot);
|
|
10526
|
+
function recurse(existing, destination) {
|
|
10527
|
+
const stat = (0, fs_1.statSync)(existing);
|
|
10528
|
+
if (!stat.isDirectory()) {
|
|
10529
|
+
try {
|
|
10530
|
+
(0, fs_1.linkSync)(existing, destination);
|
|
10531
|
+
} catch {
|
|
10532
|
+
(0, fs_1.copyFileSync)(existing, destination);
|
|
10533
|
+
}
|
|
10534
|
+
return;
|
|
10535
|
+
}
|
|
10536
|
+
(0, fs_1.mkdirSync)(destination, {
|
|
10537
|
+
recursive: true
|
|
10538
|
+
});
|
|
10539
|
+
for (const file of (0, fs_1.readdirSync)(existing)) {
|
|
10540
|
+
recurse((0, path_1.join)(existing, file), (0, path_1.join)(destination, file));
|
|
10541
|
+
}
|
|
10462
10542
|
}
|
|
10463
10543
|
}
|
|
10464
10544
|
exports.link = link;
|
|
@@ -10489,13 +10569,13 @@ var __webpack_modules__ = {
|
|
|
10489
10569
|
const serialization_1 = __webpack_require__(8614);
|
|
10490
10570
|
const OBJID_SYMBOL = Symbol.for("$__jsii__objid__$");
|
|
10491
10571
|
const IFACES_SYMBOL = Symbol.for("$__jsii__interfaces__$");
|
|
10492
|
-
const JSII_TYPE_FQN_SYMBOL = Symbol("$__jsii__fqn__$");
|
|
10493
10572
|
const JSII_RTTI_SYMBOL = Symbol.for("jsii.rtti");
|
|
10573
|
+
const RESOLVED_TYPE_FQN = new WeakMap;
|
|
10494
10574
|
function jsiiTypeFqn(obj, isVisibleType) {
|
|
10495
10575
|
var _a;
|
|
10496
10576
|
const ctor = obj.constructor;
|
|
10497
|
-
if (ctor
|
|
10498
|
-
return ctor
|
|
10577
|
+
if (RESOLVED_TYPE_FQN.has(ctor)) {
|
|
10578
|
+
return RESOLVED_TYPE_FQN.get(ctor);
|
|
10499
10579
|
}
|
|
10500
10580
|
let curr = ctor;
|
|
10501
10581
|
while ((_a = curr[JSII_RTTI_SYMBOL]) === null || _a === void 0 ? void 0 : _a.fqn) {
|
|
@@ -10539,15 +10619,11 @@ var __webpack_modules__ = {
|
|
|
10539
10619
|
});
|
|
10540
10620
|
}
|
|
10541
10621
|
function tagJsiiConstructor(constructor, fqn) {
|
|
10542
|
-
|
|
10543
|
-
|
|
10622
|
+
const existing = RESOLVED_TYPE_FQN.get(constructor);
|
|
10623
|
+
if (existing != null) {
|
|
10624
|
+
return assert.strictEqual(existing, fqn, `Unable to register ${constructor.name} as ${fqn}: it is already registerd with FQN ${existing}`);
|
|
10544
10625
|
}
|
|
10545
|
-
|
|
10546
|
-
configurable: false,
|
|
10547
|
-
enumerable: false,
|
|
10548
|
-
writable: false,
|
|
10549
|
-
value: fqn
|
|
10550
|
-
});
|
|
10626
|
+
RESOLVED_TYPE_FQN.set(constructor, fqn);
|
|
10551
10627
|
}
|
|
10552
10628
|
exports.tagJsiiConstructor = tagJsiiConstructor;
|
|
10553
10629
|
class ObjectTable {
|
|
@@ -11467,32 +11543,12 @@ var __webpack_modules__ = {
|
|
|
11467
11543
|
default_cache_root_1.defaultCacheRoot)();
|
|
11468
11544
|
const dirCache = disk_cache_1.DiskCache.inDirectory(cacheRoot);
|
|
11469
11545
|
const entry = dirCache.entryFor(file, ...comments);
|
|
11470
|
-
const {path, cache} = entry.
|
|
11471
|
-
|
|
11472
|
-
|
|
11473
|
-
|
|
11474
|
-
|
|
11475
|
-
|
|
11476
|
-
try {
|
|
11477
|
-
untarInto({
|
|
11478
|
-
...options,
|
|
11479
|
-
cwd: entry.path,
|
|
11480
|
-
file
|
|
11481
|
-
});
|
|
11482
|
-
} catch (error) {
|
|
11483
|
-
(0, fs_1.rmSync)(entry.path, {
|
|
11484
|
-
force: true,
|
|
11485
|
-
recursive: true
|
|
11486
|
-
});
|
|
11487
|
-
throw error;
|
|
11488
|
-
}
|
|
11489
|
-
cache = "miss";
|
|
11490
|
-
}
|
|
11491
|
-
lock.touch();
|
|
11492
|
-
return {
|
|
11493
|
-
path: entry.path,
|
|
11494
|
-
cache
|
|
11495
|
-
};
|
|
11546
|
+
const {path, cache} = entry.retrieve((path => {
|
|
11547
|
+
untarInto({
|
|
11548
|
+
...options,
|
|
11549
|
+
cwd: path,
|
|
11550
|
+
file
|
|
11551
|
+
});
|
|
11496
11552
|
}));
|
|
11497
11553
|
(0, link_1.link)(path, outDir);
|
|
11498
11554
|
return {
|
|
@@ -17370,7 +17426,7 @@ var __webpack_modules__ = {
|
|
|
17370
17426
|
},
|
|
17371
17427
|
4147: module => {
|
|
17372
17428
|
"use strict";
|
|
17373
|
-
module.exports = JSON.parse('{"name":"@jsii/runtime","version":"1.
|
|
17429
|
+
module.exports = JSON.parse('{"name":"@jsii/runtime","version":"1.87.0","description":"jsii runtime kernel process","license":"Apache-2.0","author":{"name":"Amazon Web Services","url":"https://aws.amazon.com"},"homepage":"https://github.com/aws/jsii","bugs":{"url":"https://github.com/aws/jsii/issues"},"repository":{"type":"git","url":"https://github.com/aws/jsii.git","directory":"packages/@jsii/runtime"},"engines":{"node":">= 14.17.0"},"main":"lib/index.js","types":"lib/index.d.ts","bin":{"jsii-runtime":"bin/jsii-runtime"},"scripts":{"build":"tsc --build && chmod +x bin/jsii-runtime && npx webpack-cli && npm run lint","watch":"tsc --build -w","lint":"eslint . --ext .js,.ts --ignore-path=.gitignore --ignore-pattern=webpack.config.js","lint:fix":"yarn lint --fix","test":"jest","test:update":"jest -u","package":"package-js"},"dependencies":{"@jsii/kernel":"^1.87.0","@jsii/check-node":"1.87.0","@jsii/spec":"^1.87.0"},"devDependencies":{"@scope/jsii-calc-base":"^1.87.0","@scope/jsii-calc-lib":"^1.87.0","jsii-build-tools":"^1.87.0","jsii-calc":"^3.20.120","source-map-loader":"^4.0.1","webpack":"^5.88.2","webpack-cli":"^5.1.4"}}');
|
|
17374
17430
|
},
|
|
17375
17431
|
5277: module => {
|
|
17376
17432
|
"use strict";
|