@salesforce/lds-runtime-mobile 1.237.0 → 1.239.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/main.js +23 -11
- package/package.json +1 -1
- package/sfdc/main.js +23 -11
package/dist/main.js
CHANGED
|
@@ -4378,8 +4378,8 @@ function rootRecordQuery(selection, input) {
|
|
|
4378
4378
|
// If there is no metadata for this query or it somehow lacks a timestamp
|
|
4379
4379
|
// skip setting the root timestamp
|
|
4380
4380
|
if (queryMetadata !== undefined && queryMetadata.ingestionTimestamp !== undefined) {
|
|
4381
|
-
// subtract
|
|
4382
|
-
input.rootTimestamp = queryMetadata.ingestionTimestamp -
|
|
4381
|
+
// subtract 1000ms from timestamp to account for ingestion processing time
|
|
4382
|
+
input.rootTimestamp = queryMetadata.ingestionTimestamp - 1000;
|
|
4383
4383
|
}
|
|
4384
4384
|
}
|
|
4385
4385
|
return recordQuery(selection, alias, apiName, [], input);
|
|
@@ -9220,8 +9220,8 @@ async function fetchIngestionTimeStampFromDatabase(apiName, info, args, query) {
|
|
|
9220
9220
|
const results = await query(sql, [key]);
|
|
9221
9221
|
const [timestamp] = results.rows.map((row) => row[0]);
|
|
9222
9222
|
if (timestamp !== null && typeof timestamp === 'number') {
|
|
9223
|
-
//go back
|
|
9224
|
-
ingestionTimestamp = timestamp -
|
|
9223
|
+
//go back 1000 ms to adjust for margin of error when top level query is stored and when raml objects are stored
|
|
9224
|
+
ingestionTimestamp = timestamp - 1000;
|
|
9225
9225
|
}
|
|
9226
9226
|
}
|
|
9227
9227
|
return ingestionTimestamp;
|
|
@@ -15456,10 +15456,17 @@ class NimbusSqliteStore {
|
|
|
15456
15456
|
}
|
|
15457
15457
|
setMetadata(entries, segment) {
|
|
15458
15458
|
const table = this.getTable(segment);
|
|
15459
|
-
|
|
15460
|
-
|
|
15461
|
-
|
|
15462
|
-
|
|
15459
|
+
let operation;
|
|
15460
|
+
if (this.plugin.supportsBatchUpdates === undefined ||
|
|
15461
|
+
this.plugin.supportsBatchUpdates() === false) {
|
|
15462
|
+
operation = table.entriesToUpsertOperations(entries, segment);
|
|
15463
|
+
// manually set the context type on the upsert so notifications do not notify rebuilds without
|
|
15464
|
+
// plugin updates
|
|
15465
|
+
operation.context.type = 'setMetadata';
|
|
15466
|
+
}
|
|
15467
|
+
else {
|
|
15468
|
+
operation = table.metadataToUpdateOperations(entries, segment);
|
|
15469
|
+
}
|
|
15463
15470
|
return this.batchOperationAsPromise([operation]);
|
|
15464
15471
|
}
|
|
15465
15472
|
batchOperations(operations) {
|
|
@@ -15472,7 +15479,11 @@ class NimbusSqliteStore {
|
|
|
15472
15479
|
const table = this.getTable(cur.segment);
|
|
15473
15480
|
if (this.plugin.supportsBatchUpdates === undefined ||
|
|
15474
15481
|
this.plugin.supportsBatchUpdates() === false) {
|
|
15475
|
-
|
|
15482
|
+
const upsert = table.entriesToUpsertOperations(cur.entries, cur.segment);
|
|
15483
|
+
// manually set the context type on the upsert so notifications do not notify rebuilds without
|
|
15484
|
+
// plugin updates
|
|
15485
|
+
upsert.context.type = 'setMetadata';
|
|
15486
|
+
acc.push(upsert);
|
|
15476
15487
|
}
|
|
15477
15488
|
else {
|
|
15478
15489
|
acc.push(table.metadataToUpdateOperations(cur.entries, cur.segment));
|
|
@@ -15498,7 +15509,8 @@ class NimbusSqliteStore {
|
|
|
15498
15509
|
// if our context contains a type then set that as our main level type
|
|
15499
15510
|
// allows us in the future of updates to specify the segment change happening
|
|
15500
15511
|
// example being update call on metadata only or updating data
|
|
15501
|
-
if (c.type === 'update'
|
|
15512
|
+
if ((c.type === 'update' || c.type === 'upsert') &&
|
|
15513
|
+
c.context.type !== undefined) {
|
|
15502
15514
|
type = c.context.type;
|
|
15503
15515
|
}
|
|
15504
15516
|
return {
|
|
@@ -17047,4 +17059,4 @@ register({
|
|
|
17047
17059
|
});
|
|
17048
17060
|
|
|
17049
17061
|
export { getRuntime, registerReportObserver, reportGraphqlQueryParseError };
|
|
17050
|
-
// version: 1.
|
|
17062
|
+
// version: 1.239.0-6c531185a
|
package/package.json
CHANGED
package/sfdc/main.js
CHANGED
|
@@ -4378,8 +4378,8 @@ function rootRecordQuery(selection, input) {
|
|
|
4378
4378
|
// If there is no metadata for this query or it somehow lacks a timestamp
|
|
4379
4379
|
// skip setting the root timestamp
|
|
4380
4380
|
if (queryMetadata !== undefined && queryMetadata.ingestionTimestamp !== undefined) {
|
|
4381
|
-
// subtract
|
|
4382
|
-
input.rootTimestamp = queryMetadata.ingestionTimestamp -
|
|
4381
|
+
// subtract 1000ms from timestamp to account for ingestion processing time
|
|
4382
|
+
input.rootTimestamp = queryMetadata.ingestionTimestamp - 1000;
|
|
4383
4383
|
}
|
|
4384
4384
|
}
|
|
4385
4385
|
return recordQuery(selection, alias, apiName, [], input);
|
|
@@ -9220,8 +9220,8 @@ async function fetchIngestionTimeStampFromDatabase(apiName, info, args, query) {
|
|
|
9220
9220
|
const results = await query(sql, [key]);
|
|
9221
9221
|
const [timestamp] = results.rows.map((row) => row[0]);
|
|
9222
9222
|
if (timestamp !== null && typeof timestamp === 'number') {
|
|
9223
|
-
//go back
|
|
9224
|
-
ingestionTimestamp = timestamp -
|
|
9223
|
+
//go back 1000 ms to adjust for margin of error when top level query is stored and when raml objects are stored
|
|
9224
|
+
ingestionTimestamp = timestamp - 1000;
|
|
9225
9225
|
}
|
|
9226
9226
|
}
|
|
9227
9227
|
return ingestionTimestamp;
|
|
@@ -15456,10 +15456,17 @@ class NimbusSqliteStore {
|
|
|
15456
15456
|
}
|
|
15457
15457
|
setMetadata(entries, segment) {
|
|
15458
15458
|
const table = this.getTable(segment);
|
|
15459
|
-
|
|
15460
|
-
|
|
15461
|
-
|
|
15462
|
-
|
|
15459
|
+
let operation;
|
|
15460
|
+
if (this.plugin.supportsBatchUpdates === undefined ||
|
|
15461
|
+
this.plugin.supportsBatchUpdates() === false) {
|
|
15462
|
+
operation = table.entriesToUpsertOperations(entries, segment);
|
|
15463
|
+
// manually set the context type on the upsert so notifications do not notify rebuilds without
|
|
15464
|
+
// plugin updates
|
|
15465
|
+
operation.context.type = 'setMetadata';
|
|
15466
|
+
}
|
|
15467
|
+
else {
|
|
15468
|
+
operation = table.metadataToUpdateOperations(entries, segment);
|
|
15469
|
+
}
|
|
15463
15470
|
return this.batchOperationAsPromise([operation]);
|
|
15464
15471
|
}
|
|
15465
15472
|
batchOperations(operations) {
|
|
@@ -15472,7 +15479,11 @@ class NimbusSqliteStore {
|
|
|
15472
15479
|
const table = this.getTable(cur.segment);
|
|
15473
15480
|
if (this.plugin.supportsBatchUpdates === undefined ||
|
|
15474
15481
|
this.plugin.supportsBatchUpdates() === false) {
|
|
15475
|
-
|
|
15482
|
+
const upsert = table.entriesToUpsertOperations(cur.entries, cur.segment);
|
|
15483
|
+
// manually set the context type on the upsert so notifications do not notify rebuilds without
|
|
15484
|
+
// plugin updates
|
|
15485
|
+
upsert.context.type = 'setMetadata';
|
|
15486
|
+
acc.push(upsert);
|
|
15476
15487
|
}
|
|
15477
15488
|
else {
|
|
15478
15489
|
acc.push(table.metadataToUpdateOperations(cur.entries, cur.segment));
|
|
@@ -15498,7 +15509,8 @@ class NimbusSqliteStore {
|
|
|
15498
15509
|
// if our context contains a type then set that as our main level type
|
|
15499
15510
|
// allows us in the future of updates to specify the segment change happening
|
|
15500
15511
|
// example being update call on metadata only or updating data
|
|
15501
|
-
if (c.type === 'update'
|
|
15512
|
+
if ((c.type === 'update' || c.type === 'upsert') &&
|
|
15513
|
+
c.context.type !== undefined) {
|
|
15502
15514
|
type = c.context.type;
|
|
15503
15515
|
}
|
|
15504
15516
|
return {
|
|
@@ -17047,4 +17059,4 @@ register({
|
|
|
17047
17059
|
});
|
|
17048
17060
|
|
|
17049
17061
|
export { getRuntime, registerReportObserver, reportGraphqlQueryParseError };
|
|
17050
|
-
// version: 1.
|
|
17062
|
+
// version: 1.239.0-6c531185a
|