ahmed-rivet-convex 2.2.0 → 2.2.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.
|
@@ -4366,7 +4366,10 @@ async function persistDD31(lc, clientID, memdag, perdag, mutators, closed, forma
|
|
|
4366
4366
|
if (compareCookiesForSnapshots(
|
|
4367
4367
|
memdagBaseSnapshot,
|
|
4368
4368
|
latestPerdagBaseSnapshot
|
|
4369
|
-
) > 0
|
|
4369
|
+
) > 0 && mutationIDsAreAtLeast(
|
|
4370
|
+
memdagBaseSnapshot.meta.lastMutationIDs,
|
|
4371
|
+
latestPerdagBaseSnapshot.meta.lastMutationIDs
|
|
4372
|
+
)) {
|
|
4370
4373
|
memdagBaseSnapshotPersisted = true;
|
|
4371
4374
|
await Promise.all(
|
|
4372
4375
|
Array.from(gatheredChunks.values(), (c) => perdagWrite.putChunk(c))
|
|
@@ -4429,6 +4432,14 @@ async function persistDD31(lc, clientID, memdag, perdag, mutators, closed, forma
|
|
|
4429
4432
|
);
|
|
4430
4433
|
}
|
|
4431
4434
|
}
|
|
4435
|
+
function mutationIDsAreAtLeast(candidate, durable) {
|
|
4436
|
+
for (const [clientID, durableMutationID] of Object.entries(durable)) {
|
|
4437
|
+
if ((candidate[clientID] ?? 0) < durableMutationID) {
|
|
4438
|
+
return false;
|
|
4439
|
+
}
|
|
4440
|
+
}
|
|
4441
|
+
return true;
|
|
4442
|
+
}
|
|
4432
4443
|
async function getClientGroupInfo(perdagRead, clientGroupID) {
|
|
4433
4444
|
const clientGroup = await getClientGroup(clientGroupID, perdagRead);
|
|
4434
4445
|
assert(clientGroup, `No client group for clientGroupID: ${clientGroupID}`);
|
|
@@ -5160,9 +5171,9 @@ var version = "15.2.1";
|
|
|
5160
5171
|
|
|
5161
5172
|
// ../replicache/src/replicache-impl.ts
|
|
5162
5173
|
var MAX_REAUTH_TRIES = 8;
|
|
5163
|
-
var PERSIST_IDLE_TIMEOUT_MS =
|
|
5174
|
+
var PERSIST_IDLE_TIMEOUT_MS = 50;
|
|
5164
5175
|
var REFRESH_IDLE_TIMEOUT_MS = 16;
|
|
5165
|
-
var PERSIST_THROTTLE_MS =
|
|
5176
|
+
var PERSIST_THROTTLE_MS = 250;
|
|
5166
5177
|
var REFRESH_THROTTLE_MS = 32;
|
|
5167
5178
|
var LAZY_STORE_SOURCE_CHUNK_CACHE_SIZE_LIMIT = 100 * 2 ** 20;
|
|
5168
5179
|
var RECOVER_MUTATIONS_INTERVAL_MS = 5 * 60 * 1e3;
|
|
@@ -14995,7 +15006,7 @@ function makeMessage(message, context, logLevel) {
|
|
|
14995
15006
|
}
|
|
14996
15007
|
|
|
14997
15008
|
// ../zero-client/src/client/version.ts
|
|
14998
|
-
var version2 = "2.2.
|
|
15009
|
+
var version2 = "2.2.2";
|
|
14999
15010
|
|
|
15000
15011
|
// ../zero-client/src/client/log-options.ts
|
|
15001
15012
|
var LevelFilterLogSink = class {
|
|
@@ -16763,6 +16774,9 @@ var Zero = class _Zero {
|
|
|
16763
16774
|
minDelayMs: 0
|
|
16764
16775
|
},
|
|
16765
16776
|
licenseKey: "zero-client-static-key",
|
|
16777
|
+
// Let the app bound snapshot retention. Undefined keeps Replicache's
|
|
16778
|
+
// 24h default; ReplicacheImpl validates the floor and throws below it.
|
|
16779
|
+
clientMaxAgeMs: options.clientMaxAgeMs,
|
|
16766
16780
|
kvStore
|
|
16767
16781
|
};
|
|
16768
16782
|
this.#zeroContext = new ZeroContext(
|
|
@@ -18073,4 +18087,4 @@ export {
|
|
|
18073
18087
|
pako/dist/pako.esm.mjs:
|
|
18074
18088
|
(*! pako 2.1.0 https://github.com/nodeca/pako @license (MIT AND Zlib) *)
|
|
18075
18089
|
*/
|
|
18076
|
-
//# sourceMappingURL=chunk-
|
|
18090
|
+
//# sourceMappingURL=chunk-ESPGEVYR.js.map
|