@framers/agentos-ext-account-sources 0.8.0 → 0.9.1
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/README.md +20 -6
- package/dist/sync/SqlAccountSourceSyncStore.d.ts +68 -26
- package/dist/sync/SqlAccountSourceSyncStore.d.ts.map +1 -1
- package/dist/sync/SqlAccountSourceSyncStore.js +191 -34
- package/dist/sync/SqlAccountSourceSyncStore.js.map +1 -1
- package/dist/sync/state.d.ts +28 -0
- package/dist/sync/state.d.ts.map +1 -1
- package/dist/sync/state.js +48 -0
- package/dist/sync/state.js.map +1 -1
- package/dist/sync/types.d.ts +28 -1
- package/dist/sync/types.d.ts.map +1 -1
- package/manifest.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -166,7 +166,7 @@ A `SourceSyncDocument` holds a `SourceRead` with text, its message spans as UTF-
|
|
|
166
166
|
| `needs_reconnecting` | The grant was refused or lacks a scope; the cursor and use switches are cleared |
|
|
167
167
|
| `disconnected` | The connection ended; the cursor and use switches are cleared |
|
|
168
168
|
|
|
169
|
-
Pause is the `paused` flag on a connected or syncing connection, not a state: it stops syncs and keeps the cursor. Connecting, grant loss, disconnecting, pause, resume, a policy change and a use change each raise `generation`, so a store can refuse work started under an earlier one. A policy change also clears the cursor, so the next cycle applies the new bounds from a fresh pass. Connecting, pause, resume, a policy change, grant loss and disconnecting set `revalidationRequired`; a successful sync clears it. Disconnecting a disconnected connection, pausing a paused one and resuming an unpaused one answer the same state.
|
|
169
|
+
Pause is the `paused` flag on a connected or syncing connection, not a state: it stops syncs and keeps the cursor. Connecting, grant loss, disconnecting, pause, resume, a policy change and a use change each raise `generation`, so a store can refuse work started under an earlier one. A policy change also clears the cursor, so the next cycle applies the new bounds from a fresh pass. Connecting, pause, resume, a policy change, grant loss and disconnecting set `revalidationRequired`; a successful sync clears it. A tune (`policy_tuned`) records a policy whose operating bounds alone changed: in any state it moves `revision` and `updatedAt` and keeps the generation, cursor, `revalidationRequired`, progress and schedule. Disconnecting a disconnected connection, pausing a paused one and resuming an unpaused one answer the same state.
|
|
170
170
|
|
|
171
171
|
`sourceSyncDue(state, policy, now, trigger)` is false unless the connection is connected or syncing, unpaused and at or after any `retryAt`. A `'scheduled'` trigger is then due once `nextSyncAt` is reached; a `'manual'` one when no request was made yet or `manualMinIntervalMs` has passed since the last. A deferred sync keeps the cursor and sets `retryAt`. A `domain_policy` or `invalid_response` failure clears `nextSyncAt`, so no scheduled sync is due until a manual request or another control change sets it.
|
|
172
172
|
|
|
@@ -174,7 +174,7 @@ Pause is the `paused` flag on a connected or syncing connection, not a state: it
|
|
|
174
174
|
|
|
175
175
|
`openSourceSyncCycle(input)` opens a checkpoint at revision 0 and throws `invalid_source_sync_checkpoint` for an empty or oversized id or anchor, a generation or cutoff that is not a nonnegative safe integer, or an unknown mode. An `incremental` cycle starts with history from the committed cursor; `bootstrap`, `reconcile` and `recovery` start with a scan, and their history then replays from the checkpoint's `fromCursor`: an anchor read before the scan for `bootstrap` and `recovery`, the committed cursor for `reconcile`, or its anchor when the provider answers that the history from that cursor has expired (see [The coordinator](#the-coordinator)). `advanceSourceSyncPage(checkpoint, page, policy)` answers the next checkpoint and the ids to queue, without duplicates:
|
|
176
176
|
|
|
177
|
-
- A scan that reaches `maxScanPages` pages or `maxCandidates` ids with more left keeps the first ids in the order given, marks the checkpoint `bounded` and stops. A finished scan moves the cycle to history from the same anchor.
|
|
177
|
+
- A scan that reaches `maxScanPages` pages or `maxCandidates` ids with more left keeps the first ids in the order given, marks the checkpoint `bounded` and stops. A finished scan moves the cycle to history from the same anchor. A scan that goes on keeps the `scanPageSize` its next page token was read under as the checkpoint's `pageTokenSize`, which a finished scan drops.
|
|
178
178
|
- A history page records its cursor as the target. The last page, with no next page token, moves the cycle to `apply`.
|
|
179
179
|
- A page of the wrong kind for the phase, a scan page past the bounds or larger than `scanPageSize`, an empty or oversized id, cursor or page token, or a page whose next token is the token it was read with throws `invalid_source_sync_page`.
|
|
180
180
|
|
|
@@ -184,6 +184,8 @@ The rules are pure and take no lock: the store that commits a cursor reads the s
|
|
|
184
184
|
|
|
185
185
|
`new SourceSyncFault(code, retryAt?)` carries a fixed failure code as its message (`source_sync_<code>`), never a provider's text, exposes `code` and `retryAt`, and throws `invalid_source_sync_fault` for an unknown code or a `retryAt` that is not a nonnegative safe integer. `assertSourceSyncPolicy(policy)` throws `invalid_source_sync_policy` unless every policy value is a positive safe integer.
|
|
186
186
|
|
|
187
|
+
`SOURCE_SYNC_OPERATING_BOUNDS` names the nine policy values that bound how a connection syncs rather than what it keeps: `scanPageSize`, `maxScanPages`, `maxCandidates`, `maxChangedPerLease`, `maxHistoryPagesPerLease`, `leaseMs`, `pollMs`, `manualMinIntervalMs` and `reconcileMs`. `sourceSyncContentChanges(stored, next)` answers every other key whose value differs between two policies, in key order: the window, the retained, held and indexed ceilings, and any key a host adds to the policies it stores, a key only one of them holds included, with values compared as JSON. An empty answer means a tune can store `next`; anything else takes a policy change.
|
|
188
|
+
|
|
187
189
|
### The SQL store
|
|
188
190
|
|
|
189
191
|
```ts
|
|
@@ -213,7 +215,7 @@ The host supplies seven bindings, and may supply an eighth, `refresh`. The store
|
|
|
213
215
|
| `active(tx, owner)` | Answers false for an account that is deleted or being deleted, whose admission is off or whose purge is pending; the store then claims, commits and reactivates nothing for it and answers no source state |
|
|
214
216
|
| `allowance(tx, scope)` | Answers the connection's document and held-character ceilings after unrelated sources, and the remaining indexing balance |
|
|
215
217
|
| `write(tx, scope, dependency, document, prepared)` | Writes the document's text and the host's prepared passages and vectors |
|
|
216
|
-
| `chargeIndexed(tx, scope, characters)` | Charges
|
|
218
|
+
| `chargeIndexed(tx, scope, characters)` | Charges the characters a committed write adds to index: a read's whole text, or, against a copy the store still holds, the read's new and changed messages and the text beside them (a changed header line or separator counts, as does the separator of a message that moved after another neighbour); never called for a read that adds nothing |
|
|
217
219
|
| `purge(tx, owner, affected)` | Deletes the host's text, passages and vectors in the affected scope |
|
|
218
220
|
| `purgeResults(tx, owner, ids)` | Deletes the host's rows for these derived results |
|
|
219
221
|
| `rebind(tx, scope, generation)` | Moves the connection's host rows to a new generation without changing their content, version or expiry |
|
|
@@ -223,11 +225,23 @@ Provider reads, embedding and model calls run between store calls, never inside
|
|
|
223
225
|
|
|
224
226
|
A sync holds a lease. `claim(scope, trigger)` answers a handle only when the owner is active, the `active` binding agrees, no barrier or live lease is set and `sourceSyncDue` holds; `renew(handle)` extends the lease by `leaseMs`; `release(handle, event?)` gives it up, records a deferral or a fixed failure when one is given, and keeps the checkpoint and work for the next claim. `openCycle` opens a checkpoint or answers the one already open, `page` records a page and queues its ids in one transaction (the same page sent again right after answers the same checkpoint; any other stale revision answers null), and `takeWork` marks the next due item attempted before the read; an item that reached five attempts without a recorded result is not taken but waits `pollMs` as a `storage_unavailable` retry. Every call made with a handle checks the owner fence, the lease token and expiry, the generation and the `active` binding in the same transaction; once any of them has moved on, `release(handle)` answers false and every other call answers null.
|
|
225
227
|
|
|
226
|
-
`applyResult(handle, work, result, prepared)` keeps a `retry` result unresolved. A `document` result is weighed first: the store ranks this connection's retained sources and the new one by activity time, newest first with ties broken by source id, and keeps those inside `maxRetainedDocuments`, `maxHeldCharacters` and the allowance. A document that does not fit is recorded as skipped with `document_limit`, `held_limit` or `indexing_limit`, and an excluded one with `excluded`. A document that fits replaces the source's previous copy in the same transaction (host write, indexing charge and provenance), after that copy and every derived result that depends on it are removed through the fence, and this connection's other sources the limits no longer admit are removed with it, never another connection's. A read that repeats the text and message spans of a copy the store still holds, within its expiry and window, adds nothing to index: it is charged nothing and is not weighed against the indexing allowance, so neither a reconcile that reads every retained source again nor a change to a source's labels or history spends any of it. When the read also repeats the copy's version and content hash, the `refresh` binding keeps the copy in place, with every result derived from it, and gives it the read's expiry and message windows; otherwise, and for a host without the binding, the copy is written again from a fresh preparation. A `gone` result, a skip and an excluded document remove the source's previous copy, except an `indexing_limit` skip whose previous copy is within its expiry and window, still admitted as it is by the retained limits, and where the new read begins: the read's text starts with the copy's text, by the hash the store keeps of it, and holds every message of it at the same span. That copy, admitted and charged under an earlier read, stays with the shorter of its own and the read's expiry and message windows until a later read of the source finds room in the allowance (a change to it, or a reconcile) or the copy expires; a read that lost or changed one of its messages removes it. A copy past its expiry or window counts as not held, whether or not `expire` has removed it yet. Given `prepared` as null, a document the store has to write answers `pending` with the same handle and records nothing; apply it again with its prepared value. Such a document reaches the `allowance` binding in both calls, so keep that binding to reads. A failing binding rolls the whole application back. The answer carries a new handle whenever a removal advanced the owner's fence; later calls use it. `finish` commits the cycle's target cursor once every work item is terminal, counting from the stored work, and `progress` records the counts so far.
|
|
228
|
+
`applyResult(handle, work, result, prepared)` keeps a `retry` result unresolved. A `document` result is weighed first: the store ranks this connection's retained sources and the new one by activity time, newest first with ties broken by source id, and keeps those inside `maxRetainedDocuments`, `maxHeldCharacters` and the allowance. A document that does not fit is recorded as skipped with `document_limit`, `held_limit` or `indexing_limit`, and an excluded one with `excluded`. A document that fits replaces the source's previous copy in the same transaction (host write, indexing charge and provenance), after that copy and every derived result that depends on it are removed through the fence, and this connection's other sources the limits no longer admit are removed with it, never another connection's. A read that repeats the text and message spans of a copy the store still holds, within its expiry and window, adds nothing to index: it is charged nothing and is not weighed against the indexing allowance, so neither a reconcile that reads every retained source again nor a change to a source's labels or history spends any of it. Any other read of such a copy is weighed against the indexing allowance and charged by its new and changed messages: the store keeps the hash of each message's text, and a message the copy holds with the same id, text hash, cut and length is free, as is the text before it (its separator and any header lines) when that text is the copy's and the message before it is the one the copy has there, itself unchanged (`leadHash` on each span); a changed header line or separator is charged, and so are the separator after an edited message and the separator of a message that follows another neighbour than it did. A reply is charged its separator and text, a message edited in place is charged with the separators beside it, and a read that only drops messages is charged nothing. A connector that caps a thread's text and spends it on the newest messages first, as Gmail's does under its `maxThreadCharacters`, cuts the oldest message shorter at each reply near the cap: that message is charged again at its new length, with the separator after it, and the rest of the thread is not. A copy whose messages keep no text hash, as an earlier release wrote it, is weighed by the hash of its whole text instead: a read that begins with that text, every message of the copy at the same span, is charged what follows it, and any other read, like every read of a copy without either hash, is charged in full. When the read also repeats the copy's version and content hash, the `refresh` binding keeps the copy in place, with every result derived from it, and gives it the read's expiry and message windows; otherwise, and for a host without the binding, the copy is written again from a fresh preparation. A `gone` result, a skip and an excluded document remove the source's previous copy, except an `indexing_limit` skip whose previous copy is within its expiry and window, still admitted as it is by the retained limits, and where the new read begins: the read's text starts with the copy's text, by the hash the store keeps of it, and holds every message of it at the same span. That copy, admitted and charged under an earlier read, stays with the shorter of its own and the read's expiry and message windows until a later read of the source finds room in the allowance (a change to it, or a reconcile) or the copy expires; a read that lost or changed one of its messages removes it. A reply that cuts the oldest message of a thread at the cap changes that message, so with the allowance spent it removes the thread's copy, and the thread stays out of the store until a read of it fits the allowance whole. A copy past its expiry or window counts as not held, whether or not `expire` has removed it yet. Given `prepared` as null, a document the store has to write answers `pending` with the same handle and records nothing; apply it again with its prepared value. Such a document reaches the `allowance` binding in both calls, so keep that binding to reads. A failing binding rolls the whole application back. The answer carries a new handle whenever a removal advanced the owner's fence; later calls use it. `finish` commits the cycle's target cursor once every work item is terminal, counting from the stored work, and `progress` records the counts so far.
|
|
229
|
+
|
|
230
|
+
Controls run with the owner blocked, a tune (below) aside. `control(scope, event, policy?)` applies `connect_started`, `grant_ready`, `pause`, `resume`, `use_changed`, `policy_changed` (with the new policy), `grant_lost` or `disconnect`: it records a content-free barrier and drops the open cycle in one transaction, then completes the barrier and reactivates the owner. Connecting, grant loss and disconnecting remove the connection's sources, their derived results and its exclusions. Pause, resume, a use change and a policy change move retained content to the new generation with its version kept and its expiry never extended, so no result derived before the change can be delivered again; a policy change also removes the sources the new limits leave out and shortens the expiry of the rest to the new window. `exclude(scope, sourceId)` removes one source and keeps a content-free exclusion; `resetExclusions(scope)` clears them. Both raise the generation and keep the committed cursor, and make a reconcile the next cycle: a fresh bounded scan, then history replayed from that cursor, so a change made since it reaches the store even for an item the scan does not list. A control other than disconnecting throws `stale_source_sync` while the `active` binding refuses the owner. A barrier left by a failure blocks claims and reactivation until `recoverControl(scope)` completes it, and a lifecycle worker calls it even for a paused connection. `expire(scope, limit)` removes retained sources whose expiry has passed, also while the connection is paused or the owner's fence is inactive, as for a suspended account, which stays inactive, then the owner's expired derived results; reads refuse an expired source either way. Each source goes in a transaction of its own. When a removal or the results' expiry fails, `expire` throws the failure; once it had removed a source, it throws a `SourceSyncExpiryError` with the failure's message and `cause`, whose `partial` counts the removals made before it. `sweepExpired(limit?, owner?)` does the same across every connection, or one owner's, the earliest expiry first and by the store's own expiry, however far a maintenance walk is from them, and answers `{ removed, failed }`: an owner whose removal fails, as when its host purge keeps failing, is counted and left out of the call's later reads, so a call with up to `limit` such owners never holds back another owner's copies. An owner whose derived results then fail to expire is counted too, once; the call still answers every source it removed, and the other owners' results still expire. `removeOwner(owner, remove?)` removes a stopped owner's rows in one transaction: each of its connections, with its work rows, provenance and exclusions, once every one is disconnected with no barrier, lease, work or retained source, after running the lifecycle's own `remove` in the same transaction; the core fence's owner row and deletion records stay, since they hold no content and a restore replays the deletion from them.
|
|
231
|
+
|
|
232
|
+
```ts
|
|
233
|
+
import { sourceSyncContentChanges } from '@framers/agentos-ext-account-sources';
|
|
234
|
+
|
|
235
|
+
// A release reconciles twice a day where it reconciled daily, and changes nothing a connection keeps.
|
|
236
|
+
const stored = (await store.snapshot(scope))!.policy;
|
|
237
|
+
const next = { ...stored, reconcileMs: 43_200_000 };
|
|
238
|
+
const type = sourceSyncContentChanges(stored, next).length === 0 ? 'policy_tuned' : 'policy_changed';
|
|
239
|
+
const after = await store.control(scope, { type }, next); // a tune is null while a sync holds the lease: try later
|
|
240
|
+
```
|
|
227
241
|
|
|
228
|
-
|
|
242
|
+
A tune changes a policy's operating bounds without a reset. `control(scope, { type: 'policy_tuned' }, policy)` stores a policy that differs from the stored one only in `SOURCE_SYNC_OPERATING_BOUNDS`, in one transaction under the owner fence's row lock and the connection's, and changes nothing else: it records no barrier and moves neither the generation nor the owner's epoch, so every fence ticket and derived result stays valid, and the cursor, `revalidationRequired`, progress, schedule and retained sources stay as they were, in any state. A connection `readCurrent` answered as connected is still connected, so search and delivery go on. Any other difference throws a `SourceSyncPolicyTuneError` whose `bounds` names the differing keys, as `sourceSyncContentChanges` answers them, and changes nothing: a change to what a connection keeps takes `policy_changed`. The new bounds apply from the next lease. While a lease is live a tune that would change the policy changes nothing and answers null: a sync keeps the policy it claimed its lease with, which a provider may check against the stored one before each request, as Gmail's does. Tune again once that sync ends. A lease past its time by the store's clock ends with the tune, as a claim would replace it, so a worker whose clock runs behind holds a handle no later call accepts: its next call, and the end of a request it already has in flight, are refused, and neither can be handed on as a lost grant once a provider sees the new policy. A cycle left open between leases goes on under the new bounds, except that its scan ends there, as a bounded scan ends, before its history, when it has already reached a lower `maxScanPages` or `maxCandidates`, or when the new `scanPageSize` is below the size its next page token was read under (`pageTokenSize`; for a checkpoint written before that field, the stored policy's size, which the first tune that leaves the scan open keeps as its `pageTokenSize`). The next sync stays when it was scheduled, so a new `pollMs` counts from the sync after it. A tune stores the whole policy it is given, as a policy change does, so of two tunes made from one snapshot the later one's policy stands. A tune to the stored policy answers the snapshot and changes nothing, under a live lease too, and a tune throws `stale_source_sync` while the `active` binding refuses the owner or a barrier is set, which it never completes.
|
|
229
243
|
|
|
230
|
-
`readCurrent(tx, derivation)` answers the current state of a derivation's sources for the fence's commit and delivery checks, and a connection with a barrier or pending revalidation reads as disconnected. The store's provenance decides a source's expiry: a policy change's prune and an `indexing_limit` skip that keeps a copy shorten it there without calling a binding, so a host that reads its own rows takes the earlier of its row's expiry and the one `readCurrent` answers. `snapshot(scope)` answers metadata for authenticated controls and `documents(scope)` the retained provenance; neither authorizes delivery. Work rows and barriers hold ids and fixed values only. The documents table holds provenance, message timing, counts and hashes, never text. A text hash
|
|
244
|
+
`readCurrent(tx, derivation)` answers the current state of a derivation's sources for the fence's commit and delivery checks, and a connection with a barrier or pending revalidation reads as disconnected. The store's provenance decides a source's expiry: a policy change's prune and an `indexing_limit` skip that keeps a copy shorten it there without calling a binding, so a host that reads its own rows takes the earlier of its row's expiry and the one `readCurrent` answers. `snapshot(scope)` answers metadata for authenticated controls and `documents(scope)` the retained provenance; neither authorizes delivery. Work rows and barriers hold ids and fixed values only. The documents table holds provenance, message timing, counts and hashes, never text. A copy's text hash, the text hash of each of its messages and a connector's content hash each confirm a guessed text, a short message most easily, so treat the table as content, like the host's own tables, for access, retention and backups.
|
|
231
245
|
|
|
232
246
|
### Request quotas
|
|
233
247
|
|
|
@@ -6,15 +6,15 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import type { StorageAdapter } from '@framers/sql-storage-adapter';
|
|
8
8
|
import { SqlSourceDerivationStore, type SourceDependency, type SourceDependencyState, type SourceDerivation, type SourceOwnerScope, type SourceInvalidation, type SourceFenceTicket } from '@framers/agentos/cognition/library';
|
|
9
|
-
import type { SourceSyncScope, SourceSyncState, SourceSyncPolicy, SourceSyncLease, SourceSyncTrigger, SourceSyncCheckpoint, SourceSyncCycleInput, SourceSyncPage, SourceSyncWork, SourceSyncDocument,
|
|
9
|
+
import type { SourceSyncScope, SourceSyncState, SourceSyncPolicy, SourceSyncLease, SourceSyncTrigger, SourceSyncCheckpoint, SourceSyncCycleInput, SourceSyncPage, SourceSyncWork, SourceSyncDocument, SourceSyncStoredMessageSpan, SourceSyncReadResult, SourceSyncWorkDisposition, SourceSyncTransition, SourceSyncRetryReason } from './types.js';
|
|
10
10
|
import type { SourceSyncOperationAttempt } from './coordinatorState.js';
|
|
11
11
|
/**
|
|
12
|
-
* The provenance kept for one retained source: its dependency, message spans
|
|
13
|
-
* hash and the hash of its text, never its text.
|
|
12
|
+
* The provenance kept for one retained source: its dependency, message spans with the hash of each one's text, activity
|
|
13
|
+
* time, character count, content hash and the hash of its text, never its text.
|
|
14
14
|
*/
|
|
15
15
|
export interface SourceSyncStoredDocument {
|
|
16
16
|
readonly dependency: SourceDependency;
|
|
17
|
-
readonly messages: readonly
|
|
17
|
+
readonly messages: readonly SourceSyncStoredMessageSpan[];
|
|
18
18
|
readonly activityAt: number;
|
|
19
19
|
readonly characters: number;
|
|
20
20
|
readonly contentHash: string;
|
|
@@ -48,7 +48,11 @@ export interface SourceSyncStorageBindings<Prepared> {
|
|
|
48
48
|
allowance(tx: StorageAdapter, scope: SourceSyncScope): Promise<SourceSyncAllowance>;
|
|
49
49
|
/** Writes the document's content and the prepared value under this dependency, on the given transaction. */
|
|
50
50
|
write(tx: StorageAdapter, scope: SourceSyncScope, dependency: SourceDependency, document: SourceSyncDocument, prepared: Prepared): Promise<void>;
|
|
51
|
-
/**
|
|
51
|
+
/**
|
|
52
|
+
* Charges the sanitized characters a committed write adds to index to the owner's indexing allowance: a read's whole
|
|
53
|
+
* text, or, against a copy the store still holds, the read's new and changed messages and the text beside them, as
|
|
54
|
+
* `applyResult` weighs them. The store does not call it for a read that adds nothing.
|
|
55
|
+
*/
|
|
52
56
|
chargeIndexed(tx: StorageAdapter, scope: SourceSyncScope, characters: number): Promise<void>;
|
|
53
57
|
/** Removes the host's source content in the affected scope: text, passages and vectors. */
|
|
54
58
|
purge(tx: StorageAdapter, scope: SourceOwnerScope, affected: SourceInvalidation): Promise<void>;
|
|
@@ -84,11 +88,11 @@ export interface SourceSyncHandle {
|
|
|
84
88
|
readonly lease: SourceSyncLease;
|
|
85
89
|
}
|
|
86
90
|
/**
|
|
87
|
-
* The transitions a host control applies: connecting, a ready or lost grant, pause, resume, a use or policy change,
|
|
88
|
-
* and disconnecting.
|
|
91
|
+
* The transitions a host control applies: connecting, a ready or lost grant, pause, resume, a use or policy change, a
|
|
92
|
+
* tune of the policy's operating bounds, and disconnecting.
|
|
89
93
|
*/
|
|
90
94
|
export type SourceSyncControl = Extract<SourceSyncTransition, {
|
|
91
|
-
type: 'connect_started' | 'grant_ready' | 'pause' | 'resume' | 'use_changed' | 'policy_changed' | 'grant_lost' | 'disconnect';
|
|
95
|
+
type: 'connect_started' | 'grant_ready' | 'pause' | 'resume' | 'use_changed' | 'policy_changed' | 'policy_tuned' | 'grant_lost' | 'disconnect';
|
|
92
96
|
}>;
|
|
93
97
|
/**
|
|
94
98
|
* A control's durable, content-free record of the work it still owes: purging the connection, pruning it to its
|
|
@@ -149,9 +153,10 @@ export declare class SourceSyncExpiryError extends Error {
|
|
|
149
153
|
* that owner's fence (`fence`), and a change made with a handle checks its lease, generation and host liveness in
|
|
150
154
|
* the same transaction. Applying a changed source purges its old copy and every derived result that depends on it
|
|
151
155
|
* before the replacement is written. A read that repeats the text of a copy the store holds is never charged again,
|
|
152
|
-
*
|
|
153
|
-
*
|
|
154
|
-
*
|
|
156
|
+
* one that changes it is charged, by the hash the store keeps of each message's text, its new and changed messages and
|
|
157
|
+
* the text beside them, and with the host's `refresh` binding a read of that very copy keeps it in place. Provider
|
|
158
|
+
* reads, embedding and model calls stay outside the store. The constructor runs no DDL: the host's migration runs
|
|
159
|
+
* `sourceSyncSchema` and core's `sourceDerivationSchema` first.
|
|
155
160
|
*
|
|
156
161
|
* @typeParam Prepared - The host's in-memory value for one document, passed through to its `write` binding.
|
|
157
162
|
*/
|
|
@@ -285,17 +290,30 @@ export declare class SqlAccountSourceSyncStore<Prepared = unknown> {
|
|
|
285
290
|
private choose;
|
|
286
291
|
/**
|
|
287
292
|
* Applies one read result for a work item taken in this cycle, under a live lease and the owner fence. A retry
|
|
288
|
-
* keeps the work unresolved. A document is weighed first: excluded, outside the retained limits or
|
|
289
|
-
*
|
|
290
|
-
*
|
|
291
|
-
*
|
|
292
|
-
*
|
|
293
|
-
*
|
|
294
|
-
* and
|
|
295
|
-
*
|
|
296
|
-
*
|
|
297
|
-
*
|
|
298
|
-
*
|
|
293
|
+
* keeps the work unresolved. A document is weighed first: excluded, outside the retained limits or over the
|
|
294
|
+
* indexing allowance with the characters it adds to index, it is recorded as a skip with its reason. A document
|
|
295
|
+
* that fits replaces the source's old copy in the same transaction (host write, indexing charge and provenance),
|
|
296
|
+
* after the old copy and every result derived from it are purged, evicting this connection's older sources the
|
|
297
|
+
* limits no longer admit. A read that repeats the text and message spans of a copy the store still holds, within
|
|
298
|
+
* its expiry and window, adds nothing to index and is never charged. Any other read of such a copy adds its new and
|
|
299
|
+
* changed messages and is weighed and charged by them alone: a message the copy holds with the same id, text hash,
|
|
300
|
+
* cut and length is free, as is the text before it (its separator and any header lines) when that text is the
|
|
301
|
+
* copy's and the message before it is the one the copy has there, itself unchanged. A reply adds its separator and
|
|
302
|
+
* text, a message edited in place adds itself with the separators on both sides of it, a changed header line or
|
|
303
|
+
* separator adds the text it is in, a message moved after another neighbour adds its separator, and a read that
|
|
304
|
+
* only drops messages adds nothing. A copy whose messages keep no text hash, as an earlier release wrote
|
|
305
|
+
* it, is weighed by the hash of its whole text: a read that begins with that text, every message of the copy at the
|
|
306
|
+
* same span, adds what follows it, and any other read adds all of itself. A connector that caps a thread's text and
|
|
307
|
+
* spends it on the newest messages first cuts the oldest message shorter at each reply near the cap: that message is
|
|
308
|
+
* charged again at its new length, with the separator after it, and the rest of the thread is not. When a repeating
|
|
309
|
+
* read also repeats the copy's version and content hash, the host's `refresh` binding keeps the copy, with every
|
|
310
|
+
* result derived from it, and gives it the read's expiry and message windows; otherwise the copy is written again
|
|
311
|
+
* from a fresh preparation. A skip and every other result purge the old copy, except an `indexing_limit` skip that
|
|
312
|
+
* finds the copy still held, still admitted as it is by the retained limits and the read beginning with its text,
|
|
313
|
+
* every message of it at the same span: that copy, admitted and charged under an earlier read, stays with the
|
|
314
|
+
* shorter of its own and the read's expiry. The read of a reply that cuts the oldest message of a thread at the cap
|
|
315
|
+
* does not begin with the copy's text, so with the allowance spent it removes the thread's copy, and the thread stays
|
|
316
|
+
* out of the store until a read of it fits the allowance whole.
|
|
299
317
|
*
|
|
300
318
|
* @param prepared - The host's prepared value for a document result; null for any other result, and for a document
|
|
301
319
|
* weighed before its preparation.
|
|
@@ -303,7 +321,9 @@ export declare class SqlAccountSourceSyncStore<Prepared = unknown> {
|
|
|
303
321
|
* handle, and nothing recorded, for a document without its prepared value that the store has to write; null for a
|
|
304
322
|
* stale handle or work item.
|
|
305
323
|
* @throws {SourceSyncFault} `invalid_response` for a result that does not match its work item or is malformed.
|
|
306
|
-
* @throws {Error} `invalid_source_allowance` when the host's allowance is not made of nonnegative safe integers
|
|
324
|
+
* @throws {Error} `invalid_source_allowance` when the host's allowance is not made of nonnegative safe integers, and
|
|
325
|
+
* `invalid_source_sync_charge` should the characters a read adds come out below zero or fractional, which the
|
|
326
|
+
* ordered spans of a valid read and an intact copy rule out; nothing is charged or written.
|
|
307
327
|
*/
|
|
308
328
|
applyResult(h: SourceSyncHandle, work: SourceSyncWork, result: SourceSyncReadResult, prepared: Prepared | null): Promise<SourceSyncApplication | null>;
|
|
309
329
|
private summary;
|
|
@@ -388,11 +408,33 @@ export declare class SqlAccountSourceSyncStore<Prepared = unknown> {
|
|
|
388
408
|
* the new policy, prunes retained sources to it and shortens their expiry to its window; the other controls rebind
|
|
389
409
|
* content to the new generation without changing its version or expiry.
|
|
390
410
|
*
|
|
391
|
-
*
|
|
392
|
-
*
|
|
393
|
-
*
|
|
411
|
+
* A tune (`policy_tuned`), which takes the new policy too, does none of that. It stores a policy that differs from the
|
|
412
|
+
* stored one only in `SOURCE_SYNC_OPERATING_BOUNDS`, in one transaction under the owner fence's row lock and the
|
|
413
|
+
* connection's: no barrier is recorded and neither the generation nor the owner's epoch moves, so every fence ticket
|
|
414
|
+
* and derived result stays valid, and the cursor, revalidation, progress, schedule and retained sources stay, in any
|
|
415
|
+
* state. The new bounds apply from the next lease. While a lease is live a tune that would change the policy changes
|
|
416
|
+
* nothing and answers null, so no sync sees its policy change; a lease past its time by this store's clock ends with
|
|
417
|
+
* the tune, as a claim would replace it. A cycle left open between leases goes on under the new bounds, except that
|
|
418
|
+
* its scan ends there, as a bounded scan ends, when it has already reached a lower `maxScanPages` or `maxCandidates`,
|
|
419
|
+
* or when the new `scanPageSize` is below the size its next page token was read under (the checkpoint's
|
|
420
|
+
* `pageTokenSize`). A tune stores the whole policy it is given, so of two tunes made from one snapshot the later one's
|
|
421
|
+
* policy stands. A tune to the stored policy answers the snapshot and changes nothing, under a live lease too.
|
|
422
|
+
*
|
|
423
|
+
* @returns The snapshot after the barrier is complete or the tune is stored; null for a tune that would change the
|
|
424
|
+
* policy while a lease is live.
|
|
425
|
+
* @throws {SourceSyncPolicyTuneError} for a tune whose policy differs from the stored one outside the operating
|
|
426
|
+
* bounds; nothing changes.
|
|
427
|
+
* @throws {Error} `source_policy_control_required` unless a policy comes exactly with `policy_changed` or
|
|
428
|
+
* `policy_tuned`, and `stale_source_sync` when the host's `active` binding refuses anything but disconnecting, a
|
|
429
|
+
* barrier is still set (a tune completes none) or the connection does not exist.
|
|
394
430
|
*/
|
|
395
431
|
control(scope: SourceSyncScope, event: SourceSyncControl, policy?: SourceSyncPolicy): Promise<SourceSyncSnapshot | null>;
|
|
432
|
+
/**
|
|
433
|
+
* Stores a tuned policy as `control` describes for `policy_tuned`.
|
|
434
|
+
*
|
|
435
|
+
* @returns The snapshot, or null when the policy would change while a lease is live.
|
|
436
|
+
*/
|
|
437
|
+
private tune;
|
|
396
438
|
private rebind;
|
|
397
439
|
/** Called by the lifecycle worker even when a connection is paused or the owner is blocked. */
|
|
398
440
|
recoverControl(scope: SourceSyncScope): Promise<void>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SqlAccountSourceSyncStore.d.ts","sourceRoot":"","sources":["../../src/sync/SqlAccountSourceSyncStore.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EACL,wBAAwB,EACxB,KAAK,gBAAgB,EAAE,KAAK,qBAAqB,EAAE,KAAK,gBAAgB,EACxE,KAAK,gBAAgB,EAAE,KAAK,kBAAkB,EAAE,KAAK,iBAAiB,EACvE,MAAM,oCAAoC,CAAC;AAC5C,OAAO,KAAK,EACV,eAAe,EAAE,eAAe,EAAE,gBAAgB,EAAE,eAAe,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