@salesforce/lds-runtime-bridge 1.274.0 → 1.276.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/dist/ldsRuntimeBridge.js +16 -31
- package/package.json +8 -8
package/dist/ldsRuntimeBridge.js
CHANGED
|
@@ -301,7 +301,7 @@ class DurableTTLStore {
|
|
|
301
301
|
}
|
|
302
302
|
}
|
|
303
303
|
|
|
304
|
-
function flushInMemoryStoreValuesToDurableStore(store, durableStore,
|
|
304
|
+
function flushInMemoryStoreValuesToDurableStore(store, durableStore, durableStoreErrorHandler, redirects, additionalDurableStoreOperations = [], enableDurableMetadataRefresh = false) {
|
|
305
305
|
const durableRecords = create$3(null);
|
|
306
306
|
const refreshedDurableRecords = create$3(null);
|
|
307
307
|
const evictedRecords = create$3(null);
|
|
@@ -341,21 +341,14 @@ function flushInMemoryStoreValuesToDurableStore(store, durableStore, crossEnviro
|
|
|
341
341
|
segment: DefaultDurableSegment,
|
|
342
342
|
});
|
|
343
343
|
}
|
|
344
|
-
|
|
344
|
+
const refreshKeys = keys$3(refreshedDurableRecords);
|
|
345
|
+
if (refreshKeys.length > 0) {
|
|
345
346
|
// publishes with only metadata updates
|
|
346
347
|
durableStoreOperations.push({
|
|
347
348
|
type: 'setMetadata',
|
|
348
349
|
entries: refreshedDurableRecords,
|
|
349
350
|
segment: DefaultDurableSegment,
|
|
350
351
|
});
|
|
351
|
-
if (crossEnvironmentNotifier !== undefined) {
|
|
352
|
-
crossEnvironmentNotifier.notifyCrossEnvironments({
|
|
353
|
-
data: {
|
|
354
|
-
refreshedDurableRecords,
|
|
355
|
-
},
|
|
356
|
-
type: 'Update',
|
|
357
|
-
});
|
|
358
|
-
}
|
|
359
352
|
}
|
|
360
353
|
// redirects
|
|
361
354
|
redirects.forEach((value, key) => {
|
|
@@ -657,14 +650,17 @@ function makeDurable(environment, { durableStore, instrumentation, useRevivingSt
|
|
|
657
650
|
}
|
|
658
651
|
// process metadata only refreshes
|
|
659
652
|
if (metadataRefreshSegmentKeys.length > 0) {
|
|
660
|
-
const
|
|
661
|
-
if (
|
|
662
|
-
const
|
|
663
|
-
|
|
664
|
-
const
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
653
|
+
const filteredKeys = metadataRefreshSegmentKeys.filter((s) => environment.storeKeyExists(s));
|
|
654
|
+
if (filteredKeys.length > 0) {
|
|
655
|
+
const entries = await durableStore.getMetadata(filteredKeys, DefaultDurableSegment);
|
|
656
|
+
if (entries !== undefined) {
|
|
657
|
+
const entryKeys = keys$3(entries);
|
|
658
|
+
for (let i = 0, len = entryKeys.length; i < len; i++) {
|
|
659
|
+
const entryKey = entryKeys[i];
|
|
660
|
+
const { metadata } = entries[entryKey];
|
|
661
|
+
if (metadata !== undefined) {
|
|
662
|
+
environment.putStoreMetadata(entryKey, metadata, false);
|
|
663
|
+
}
|
|
668
664
|
}
|
|
669
665
|
}
|
|
670
666
|
}
|
|
@@ -687,15 +683,6 @@ function makeDurable(environment, { durableStore, instrumentation, useRevivingSt
|
|
|
687
683
|
}
|
|
688
684
|
}
|
|
689
685
|
});
|
|
690
|
-
let notifier;
|
|
691
|
-
const getCrossEnvironmentNotifier = function () {
|
|
692
|
-
validateNotDisposed();
|
|
693
|
-
return notifier;
|
|
694
|
-
};
|
|
695
|
-
const setCrossEnvironmentNotifier = function (crossEnvironmentNotifier) {
|
|
696
|
-
validateNotDisposed();
|
|
697
|
-
notifier = crossEnvironmentNotifier;
|
|
698
|
-
};
|
|
699
686
|
const dispose = function () {
|
|
700
687
|
validateNotDisposed();
|
|
701
688
|
disposed = true;
|
|
@@ -748,7 +735,7 @@ function makeDurable(environment, { durableStore, instrumentation, useRevivingSt
|
|
|
748
735
|
if (stagingStore === null) {
|
|
749
736
|
return Promise.resolve();
|
|
750
737
|
}
|
|
751
|
-
const promise = flushInMemoryStoreValuesToDurableStore(stagingStore, durableStore,
|
|
738
|
+
const promise = flushInMemoryStoreValuesToDurableStore(stagingStore, durableStore, durableStoreErrorHandler, new Map(pendingStoreRedirects), additionalDurableStoreOperations, enableDurableMetadataRefresh);
|
|
752
739
|
pendingStoreRedirects.clear();
|
|
753
740
|
stagingStore = null;
|
|
754
741
|
return promise;
|
|
@@ -1118,8 +1105,6 @@ function makeDurable(environment, { durableStore, instrumentation, useRevivingSt
|
|
|
1118
1105
|
handleErrorResponse: { value: handleErrorResponse },
|
|
1119
1106
|
getNotifyChangeStoreEntries: { value: getNotifyChangeStoreEntries },
|
|
1120
1107
|
notifyStoreUpdateAvailable: { value: notifyStoreUpdateAvailable },
|
|
1121
|
-
getCrossEnvironmentNotifier: { value: getCrossEnvironmentNotifier },
|
|
1122
|
-
setCrossEnvironmentNotifier: { value: setCrossEnvironmentNotifier },
|
|
1123
1108
|
});
|
|
1124
1109
|
}
|
|
1125
1110
|
|
|
@@ -4004,4 +3989,4 @@ function ldsRuntimeBridge() {
|
|
|
4004
3989
|
}
|
|
4005
3990
|
|
|
4006
3991
|
export { ldsRuntimeBridge as default };
|
|
4007
|
-
// version: 1.
|
|
3992
|
+
// version: 1.276.0-dcebc4076
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-runtime-bridge",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.276.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "LDS runtime for bridge.app.",
|
|
6
6
|
"main": "dist/ldsRuntimeBridge.js",
|
|
@@ -34,17 +34,17 @@
|
|
|
34
34
|
"release:corejar": "yarn build && ../core-build/scripts/core.js --name=lds-runtime-bridge"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@salesforce/lds-adapters-uiapi": "^1.
|
|
38
|
-
"@salesforce/lds-instrumentation": "^1.
|
|
37
|
+
"@salesforce/lds-adapters-uiapi": "^1.276.0",
|
|
38
|
+
"@salesforce/lds-instrumentation": "^1.276.0",
|
|
39
39
|
"@salesforce/user": "0.0.21",
|
|
40
40
|
"o11y": "244.0.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@salesforce/lds-drafts-adapters-uiapi": "^1.
|
|
44
|
-
"@salesforce/lds-network-aura": "^1.
|
|
45
|
-
"@salesforce/lds-runtime-aura": "^1.
|
|
46
|
-
"@salesforce/lds-store-nimbus": "^1.
|
|
47
|
-
"@salesforce/nimbus-plugin-lds": "^1.
|
|
43
|
+
"@salesforce/lds-drafts-adapters-uiapi": "^1.276.0",
|
|
44
|
+
"@salesforce/lds-network-aura": "^1.276.0",
|
|
45
|
+
"@salesforce/lds-runtime-aura": "^1.276.0",
|
|
46
|
+
"@salesforce/lds-store-nimbus": "^1.276.0",
|
|
47
|
+
"@salesforce/nimbus-plugin-lds": "^1.276.0",
|
|
48
48
|
"babel-plugin-dynamic-import-node": "^2.3.3"
|
|
49
49
|
},
|
|
50
50
|
"luvioBundlesize": [
|