@substrat-run/kernel 0.138.0 → 0.140.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/admin-log-ddl.d.ts +21 -0
- package/dist/admin-log-ddl.d.ts.map +1 -0
- package/dist/admin-log-ddl.js +32 -0
- package/dist/admin-log-ddl.js.map +1 -0
- package/dist/attachment-extractor.d.ts +21 -2
- package/dist/attachment-extractor.d.ts.map +1 -1
- package/dist/attachment-extractor.js +31 -6
- package/dist/attachment-extractor.js.map +1 -1
- package/dist/attachment-text.d.ts +64 -0
- package/dist/attachment-text.d.ts.map +1 -1
- package/dist/attachment-text.js +87 -16
- package/dist/attachment-text.js.map +1 -1
- package/dist/attribution.d.ts +36 -3
- package/dist/attribution.d.ts.map +1 -1
- package/dist/attribution.js +21 -8
- package/dist/attribution.js.map +1 -1
- package/dist/audit-outcome.d.ts +149 -0
- package/dist/audit-outcome.d.ts.map +1 -0
- package/dist/audit-outcome.js +233 -0
- package/dist/audit-outcome.js.map +1 -0
- package/dist/connect-links.d.ts +91 -0
- package/dist/connect-links.d.ts.map +1 -0
- package/dist/connect-links.js +189 -0
- package/dist/connect-links.js.map +1 -0
- package/dist/connect-state.d.ts +12 -3
- package/dist/connect-state.d.ts.map +1 -1
- package/dist/connect-state.js +8 -3
- package/dist/connect-state.js.map +1 -1
- package/dist/derived-object.d.ts +14 -0
- package/dist/derived-object.d.ts.map +1 -0
- package/dist/derived-object.js +2 -0
- package/dist/derived-object.js.map +1 -0
- package/dist/derived-objects.d.ts +108 -0
- package/dist/derived-objects.d.ts.map +1 -0
- package/dist/derived-objects.js +199 -0
- package/dist/derived-objects.js.map +1 -0
- package/dist/email-intent.d.ts +56 -0
- package/dist/email-intent.d.ts.map +1 -0
- package/dist/email-intent.js +71 -0
- package/dist/email-intent.js.map +1 -0
- package/dist/entity-edges.d.ts +6 -1
- package/dist/entity-edges.d.ts.map +1 -1
- package/dist/entity-edges.js +13 -0
- package/dist/entity-edges.js.map +1 -1
- package/dist/entity-grant-shape.d.ts +94 -0
- package/dist/entity-grant-shape.d.ts.map +1 -0
- package/dist/entity-grant-shape.js +329 -0
- package/dist/entity-grant-shape.js.map +1 -0
- package/dist/entity-grant.d.ts +45 -0
- package/dist/entity-grant.d.ts.map +1 -0
- package/dist/entity-grant.js +71 -0
- package/dist/entity-grant.js.map +1 -0
- package/dist/entity-state-reads.d.ts +40 -0
- package/dist/entity-state-reads.d.ts.map +1 -0
- package/dist/entity-state-reads.js +91 -0
- package/dist/entity-state-reads.js.map +1 -0
- package/dist/entity-state.d.ts +204 -0
- package/dist/entity-state.d.ts.map +1 -0
- package/dist/entity-state.js +356 -0
- package/dist/entity-state.js.map +1 -0
- package/dist/entity-trash.d.ts +245 -0
- package/dist/entity-trash.d.ts.map +1 -0
- package/dist/entity-trash.js +380 -0
- package/dist/entity-trash.js.map +1 -0
- package/dist/findings.d.ts +143 -0
- package/dist/findings.d.ts.map +1 -0
- package/dist/findings.js +463 -0
- package/dist/findings.js.map +1 -0
- package/dist/grant-scoped-read.d.ts +41 -0
- package/dist/grant-scoped-read.d.ts.map +1 -0
- package/dist/grant-scoped-read.js +100 -0
- package/dist/grant-scoped-read.js.map +1 -0
- package/dist/index.d.ts +40 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +26 -6
- package/dist/index.js.map +1 -1
- package/dist/kernel-outbox.d.ts +14 -0
- package/dist/kernel-outbox.d.ts.map +1 -0
- package/dist/kernel-outbox.js +37 -0
- package/dist/kernel-outbox.js.map +1 -0
- package/dist/list-index.d.ts +34 -3
- package/dist/list-index.d.ts.map +1 -1
- package/dist/list-index.js +83 -31
- package/dist/list-index.js.map +1 -1
- package/dist/mail-sender.d.ts +78 -0
- package/dist/mail-sender.d.ts.map +1 -0
- package/dist/mail-sender.js +2 -0
- package/dist/mail-sender.js.map +1 -0
- package/dist/membership-executor.d.ts +7 -47
- package/dist/membership-executor.d.ts.map +1 -1
- package/dist/membership-executor.js +28 -53
- package/dist/membership-executor.js.map +1 -1
- package/dist/migration-digest.d.ts +161 -0
- package/dist/migration-digest.d.ts.map +1 -0
- package/dist/migration-digest.js +237 -0
- package/dist/migration-digest.js.map +1 -0
- package/dist/module-erasure.d.ts +156 -0
- package/dist/module-erasure.d.ts.map +1 -0
- package/dist/module-erasure.js +440 -0
- package/dist/module-erasure.js.map +1 -0
- package/dist/module-migrations.d.ts +6 -3
- package/dist/module-migrations.d.ts.map +1 -1
- package/dist/module-migrations.js +12 -5
- package/dist/module-migrations.js.map +1 -1
- package/dist/peer.d.ts +9 -1
- package/dist/peer.d.ts.map +1 -1
- package/dist/peer.js +29 -0
- package/dist/peer.js.map +1 -1
- package/dist/permission-checker.d.ts +6 -0
- package/dist/permission-checker.d.ts.map +1 -1
- package/dist/permission-checker.js.map +1 -1
- package/dist/permission-eval.d.ts +51 -1
- package/dist/permission-eval.d.ts.map +1 -1
- package/dist/permission-eval.js +104 -2
- package/dist/permission-eval.js.map +1 -1
- package/dist/platform-sweep.d.ts +8 -2
- package/dist/platform-sweep.d.ts.map +1 -1
- package/dist/platform-sweep.js +17 -0
- package/dist/platform-sweep.js.map +1 -1
- package/dist/scope-host.d.ts +479 -24
- package/dist/scope-host.d.ts.map +1 -1
- package/dist/scope-host.js +82 -7
- package/dist/scope-host.js.map +1 -1
- package/dist/scope-role-admin.d.ts +68 -0
- package/dist/scope-role-admin.d.ts.map +1 -0
- package/dist/scope-role-admin.js +80 -0
- package/dist/scope-role-admin.js.map +1 -0
- package/dist/search-index.d.ts +21 -1
- package/dist/search-index.d.ts.map +1 -1
- package/dist/search-index.js +60 -37
- package/dist/search-index.js.map +1 -1
- package/dist/spine-guard.d.ts +71 -2
- package/dist/spine-guard.d.ts.map +1 -1
- package/dist/spine-guard.js +393 -10
- package/dist/spine-guard.js.map +1 -1
- package/dist/spine-restore.d.ts.map +1 -1
- package/dist/spine-restore.js +5 -0
- package/dist/spine-restore.js.map +1 -1
- package/dist/sql-identifier.d.ts +12 -0
- package/dist/sql-identifier.d.ts.map +1 -0
- package/dist/sql-identifier.js +17 -0
- package/dist/sql-identifier.js.map +1 -0
- package/dist/sql-statements.d.ts +71 -0
- package/dist/sql-statements.d.ts.map +1 -0
- package/dist/sql-statements.js +191 -0
- package/dist/sql-statements.js.map +1 -0
- package/dist/subject-redaction.d.ts +9 -1
- package/dist/subject-redaction.d.ts.map +1 -1
- package/dist/subject-redaction.js.map +1 -1
- package/dist/system-switch-record.d.ts +3 -0
- package/dist/system-switch-record.d.ts.map +1 -1
- package/dist/system-switch-record.js +2 -0
- package/dist/system-switch-record.js.map +1 -1
- package/dist/table-ownership.d.ts +103 -0
- package/dist/table-ownership.d.ts.map +1 -0
- package/dist/table-ownership.js +285 -0
- package/dist/table-ownership.js.map +1 -0
- package/dist/timeline.d.ts +4 -4
- package/dist/timeline.js +4 -4
- package/dist/visible-continuation.d.ts +38 -0
- package/dist/visible-continuation.d.ts.map +1 -0
- package/dist/visible-continuation.js +162 -0
- package/dist/visible-continuation.js.map +1 -0
- package/package.json +2 -2
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { assertKernelAuthoredType, moduleId } from '@substrat-run/contracts';
|
|
2
|
+
/** The actor on every event the kernel writes itself, outside any caller's operation. */
|
|
3
|
+
export const KERNEL_ACTOR = { system: moduleId.parse('@substrat-run/kernel') };
|
|
4
|
+
/**
|
|
5
|
+
* The outbox write for an event the kernel records OUTSIDE an operation. A reconcile has no
|
|
6
|
+
* operation, no caller and no delivery, so `operation`, `caused_by` and `invocation_id` are null,
|
|
7
|
+
* which is what each says about such an event; the envelope's own fields are written as given.
|
|
8
|
+
* `version` is the deploy that wrote it.
|
|
9
|
+
*/
|
|
10
|
+
export function kernelOutboxInsertSql(e, version) {
|
|
11
|
+
assertKernelAuthoredType(e.type);
|
|
12
|
+
return {
|
|
13
|
+
sql: `INSERT INTO _substrat_outbox
|
|
14
|
+
(id, type, schema_version, occurred_at, tenant_id, scope_id, actor,
|
|
15
|
+
entity_type, entity_id, pii_class, subject_id, authorization,
|
|
16
|
+
impersonation, operation, version, caused_by, invocation_id, payload)
|
|
17
|
+
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, NULL, ?, NULL, NULL, ?)`,
|
|
18
|
+
params: [
|
|
19
|
+
e.id,
|
|
20
|
+
e.type,
|
|
21
|
+
e.schemaVersion,
|
|
22
|
+
e.occurredAt,
|
|
23
|
+
e.tenantId,
|
|
24
|
+
e.scopeId,
|
|
25
|
+
JSON.stringify(e.actor),
|
|
26
|
+
e.entity.entityType,
|
|
27
|
+
e.entity.entityId,
|
|
28
|
+
e.piiClass,
|
|
29
|
+
e.subjectId ?? null,
|
|
30
|
+
e.authorization ? JSON.stringify(e.authorization) : null,
|
|
31
|
+
e.impersonation ? JSON.stringify(e.impersonation) : null,
|
|
32
|
+
version,
|
|
33
|
+
JSON.stringify(e.payload),
|
|
34
|
+
],
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=kernel-outbox.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"kernel-outbox.js","sourceRoot":"","sources":["../src/kernel-outbox.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,QAAQ,EAAgC,MAAM,yBAAyB,CAAC;AAE3G,yFAAyF;AACzF,MAAM,CAAC,MAAM,YAAY,GAAU,EAAE,MAAM,EAAE,QAAQ,CAAC,KAAK,CAAC,sBAAsB,CAAC,EAAE,CAAC;AAEtF;;;;;GAKG;AACH,MAAM,UAAU,qBAAqB,CAAC,CAAc,EAAE,OAAsB;IAC1E,wBAAwB,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;IACjC,OAAO;QACL,GAAG,EAAE;;;;iFAIwE;QAC7E,MAAM,EAAE;YACN,CAAC,CAAC,EAAE;YACJ,CAAC,CAAC,IAAI;YACN,CAAC,CAAC,aAAa;YACf,CAAC,CAAC,UAAU;YACZ,CAAC,CAAC,QAAQ;YACV,CAAC,CAAC,OAAO;YACT,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC;YACvB,CAAC,CAAC,MAAM,CAAC,UAAU;YACnB,CAAC,CAAC,MAAM,CAAC,QAAQ;YACjB,CAAC,CAAC,QAAQ;YACV,CAAC,CAAC,SAAS,IAAI,IAAI;YACnB,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI;YACxD,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI;YACxD,OAAO;YACP,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,OAAO,CAAC;SAC1B;KACF,CAAC;AACJ,CAAC"}
|
package/dist/list-index.d.ts
CHANGED
|
@@ -42,6 +42,9 @@
|
|
|
42
42
|
* id alone (its envelope has no separate `id`, K-44).
|
|
43
43
|
*/
|
|
44
44
|
import { SubstratError } from '@substrat-run/contracts';
|
|
45
|
+
import type { EntityStateDeclaration, EntityStateName } from '@substrat-run/contracts';
|
|
46
|
+
import { type StateColumns } from './entity-state.js';
|
|
47
|
+
import type { DerivedObject } from './derived-object.js';
|
|
45
48
|
import type { SqlMigration } from './scope-host.js';
|
|
46
49
|
/**
|
|
47
50
|
* One paged read's kernel-composed half, as the kernel needs it.
|
|
@@ -71,6 +74,11 @@ export interface ListIndexPlan {
|
|
|
71
74
|
readonly filterable: readonly string[];
|
|
72
75
|
/** The index-name stem. Kernel-owned, so it carries the reserved prefix. */
|
|
73
76
|
readonly indexStem: string;
|
|
77
|
+
/**
|
|
78
|
+
* The entity's archive/trash columns, when it declares either (#119). Present, every index
|
|
79
|
+
* is PARTIAL — one per view — and every walk is narrowed to one view.
|
|
80
|
+
*/
|
|
81
|
+
readonly states?: StateColumns;
|
|
74
82
|
}
|
|
75
83
|
/** The prefix every derived list index carries. */
|
|
76
84
|
export declare const LIST_INDEX_PREFIX = "_substrat_list_";
|
|
@@ -102,7 +110,9 @@ export declare class FilterNotDeclared extends Error {
|
|
|
102
110
|
* declaration the author believes is live that silently is not produces a list
|
|
103
111
|
* that pages wrongly with no error anywhere.
|
|
104
112
|
*/
|
|
105
|
-
export declare function listIndexPlans(moduleId: string, lists: readonly ListDeclaration[] | undefined
|
|
113
|
+
export declare function listIndexPlans(moduleId: string, lists: readonly ListDeclaration[] | undefined,
|
|
114
|
+
/** The SAME module's archive/trash declarations (#119) — its table, its columns. */
|
|
115
|
+
entityStates?: readonly EntityStateDeclaration[]): ListIndexPlan[];
|
|
106
116
|
/**
|
|
107
117
|
* The index columns for one walk: the sort, then the tie-break, prefixed by a
|
|
108
118
|
* filter when the walk narrows by one.
|
|
@@ -120,6 +130,7 @@ export declare function listIndexPlans(moduleId: string, lists: readonly ListDec
|
|
|
120
130
|
export declare function listIndexColumns(plan: ListIndexPlan): {
|
|
121
131
|
name: string;
|
|
122
132
|
columns: string[];
|
|
133
|
+
where?: string;
|
|
123
134
|
}[];
|
|
124
135
|
/**
|
|
125
136
|
* The DDL for one plan's indexes.
|
|
@@ -130,6 +141,8 @@ export declare function listIndexColumns(plan: ListIndexPlan): {
|
|
|
130
141
|
* old ones. An index is derived data; nothing is lost by dropping it.
|
|
131
142
|
*/
|
|
132
143
|
export declare function listIndexDdl(plan: ListIndexPlan): string;
|
|
144
|
+
/** The plan's indexes, each with its CREATE statement — what `listIndexDdl` runs. */
|
|
145
|
+
export declare function listIndexObjects(plan: ListIndexPlan): DerivedObject[];
|
|
133
146
|
/**
|
|
134
147
|
* The migrations that provision a module's declared list indexes, journaled like
|
|
135
148
|
* any other so a scope applies them once and a changed declaration re-applies.
|
|
@@ -143,7 +156,13 @@ export declare function listIndexDdl(plan: ListIndexPlan): string;
|
|
|
143
156
|
* Appended AFTER the module's own migrations by the adapter, which is what makes
|
|
144
157
|
* the table exist by the time `CREATE INDEX` names it.
|
|
145
158
|
*/
|
|
146
|
-
export declare function listIndexMigrations(moduleId: string, lists: readonly ListDeclaration[] | undefined): SqlMigration[];
|
|
159
|
+
export declare function listIndexMigrations(moduleId: string, lists: readonly ListDeclaration[] | undefined, entityStates?: readonly EntityStateDeclaration[]): SqlMigration[];
|
|
160
|
+
/**
|
|
161
|
+
* One plan's migration version. The views are part of the declaration the DDL depends on
|
|
162
|
+
* (#119): declaring a trash makes every index partial, so the version moves and the indexes
|
|
163
|
+
* are rebuilt.
|
|
164
|
+
*/
|
|
165
|
+
export declare const listIndexVersion: (plan: ListIndexPlan) => string;
|
|
147
166
|
/**
|
|
148
167
|
* Index the plans by entity type for a whole scope, refusing an ambiguity — the
|
|
149
168
|
* same refusal `searchPlansByEntityType` makes, because `ctx.page('customer', …)`
|
|
@@ -153,6 +172,7 @@ export declare function listIndexMigrations(moduleId: string, lists: readonly Li
|
|
|
153
172
|
export declare function listPlansByEntityType(modules: readonly {
|
|
154
173
|
readonly id: string;
|
|
155
174
|
readonly lists?: readonly ListDeclaration[];
|
|
175
|
+
readonly entityStates?: readonly EntityStateDeclaration[];
|
|
156
176
|
}[]): Map<string, ListIndexPlan>;
|
|
157
177
|
/** What a caller asks for. Everything optional but the limit, which the host defaults. */
|
|
158
178
|
export interface ListQueryParams {
|
|
@@ -166,6 +186,11 @@ export interface ListQueryParams {
|
|
|
166
186
|
* the rows with no value there (`IS NULL`).
|
|
167
187
|
*/
|
|
168
188
|
readonly filters?: Readonly<Record<string, unknown>>;
|
|
189
|
+
/**
|
|
190
|
+
* Which rows (#119). `active` when unset — an archived or trashed row is never in a page
|
|
191
|
+
* nobody asked to see it in. Refused for an entity that declares no such view.
|
|
192
|
+
*/
|
|
193
|
+
readonly view?: EntityStateName;
|
|
169
194
|
}
|
|
170
195
|
/** A composed read: the page query, and the count over the same `WHERE`. */
|
|
171
196
|
export interface ComposedListQuery {
|
|
@@ -176,6 +201,8 @@ export interface ComposedListQuery {
|
|
|
176
201
|
/** The column the walk ordered by — what the cursor's first part came from. */
|
|
177
202
|
readonly sortColumn: string;
|
|
178
203
|
readonly order: 'asc' | 'desc';
|
|
204
|
+
/** The view the walk ran over (#119) — what its cursors are minted for. */
|
|
205
|
+
readonly view: EntityStateName;
|
|
179
206
|
}
|
|
180
207
|
/**
|
|
181
208
|
* Split a composite cursor into its sort value and its tie-break id.
|
|
@@ -203,7 +230,11 @@ export declare class CursorMismatch extends SubstratError {
|
|
|
203
230
|
constructor(message: string);
|
|
204
231
|
}
|
|
205
232
|
/** Build the cursor a row hands to the next page — the walk that minted it, and where. */
|
|
206
|
-
export declare function cursorOf(row: Record<string, unknown>, sortColumn: string, idColumn: string, order: 'asc' | 'desc'
|
|
233
|
+
export declare function cursorOf(row: Record<string, unknown>, sortColumn: string, idColumn: string, order: 'asc' | 'desc',
|
|
234
|
+
/** The walk's view (#119). `active`, or unset, is left out of the envelope. */
|
|
235
|
+
view?: EntityStateName): string;
|
|
236
|
+
/** Migration gate for filtered walks: their old input was a plain ctx.page cursor. */
|
|
237
|
+
export declare function isPlainPageCursor(cursor: string): boolean;
|
|
207
238
|
/**
|
|
208
239
|
* Compose the page query and its count.
|
|
209
240
|
*
|
package/dist/list-index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-index.d.ts","sourceRoot":"","sources":["../src/list-index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,OAAO,EAAuB,aAAa,EAAmB,MAAM,yBAAyB,CAAC;AAE9F,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"list-index.d.ts","sourceRoot":"","sources":["../src/list-index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,OAAO,EAAuB,aAAa,EAAmB,MAAM,yBAAyB,CAAC;AAE9F,OAAO,KAAK,E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AE,MAAM,CAAC;IAC5B,QAAQ,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAAC;IAC/B,2EAA2E;IAC3E,QAAQ,CAAC,IAAI,EAAE,eAAe,CAAC;CAChC;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,CAIrF;AAED;;;;;;;;;;GAUG;AACH,qBAAa,cAAe,SAAQ,aAAa;IAC/C,YAAY,OAAO,EAAE,MAAM,EAI1B;CACF;AA4BD,0FAA0F;AAC1F,wBAAgB,QAAQ,CACtB,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC5B,UAAU,EAAE,MAAM,EAClB,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,KAAK,GAAG,MAAM;AACrB,+EAA+E;AAC/E,IAAI,CAAC,EAAE,eAAe,GACrB,MAAM,CAUR;AAaD,sFAAsF;AACtF,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAKzD;AAmED;;;;;;;;;GASG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,aAAa,EAAE,MAAM,EAAE,eAAe,GAAG,iBAAiB,CAuFzF"}
|
package/dist/list-index.js
CHANGED
|
@@ -43,25 +43,15 @@
|
|
|
43
43
|
*/
|
|
44
44
|
import { PAGE_CURSOR_RESTART, SubstratError, ULID_PATTERN, z } from '@substrat-run/contracts';
|
|
45
45
|
import { fromBase64url, toBase64url } from './base64url.js';
|
|
46
|
+
import { entityStatePlans, entityStateWhere, stateColumnsOf, viewsOf } from './entity-state.js';
|
|
47
|
+
import { SQL_IDENTIFIER, assertSqlIdentifier } from './sql-identifier.js';
|
|
46
48
|
/** The prefix every derived list index carries. */
|
|
47
49
|
export const LIST_INDEX_PREFIX = '_substrat_list_';
|
|
48
50
|
/** Is this index one the kernel derived for a paged read? */
|
|
49
51
|
export function isListIndexName(name) {
|
|
50
52
|
return name.startsWith(LIST_INDEX_PREFIX);
|
|
51
53
|
}
|
|
52
|
-
|
|
53
|
-
* SQL identifiers reach the DDL by interpolation — there is no parameter form
|
|
54
|
-
* for a table or column name — so every one is checked first. Same reasoning as
|
|
55
|
-
* `search-index.ts`: a declaration is still a string somebody typed, and "it came
|
|
56
|
-
* from the manifest" is exactly the reasoning that makes an injection a surprise.
|
|
57
|
-
*/
|
|
58
|
-
const IDENTIFIER = /^[A-Za-z_][A-Za-z0-9_]*$/;
|
|
59
|
-
function assertIdentifier(kind, value, where) {
|
|
60
|
-
if (!IDENTIFIER.test(value)) {
|
|
61
|
-
throw new Error(`list: ${where} names ${kind} '${value}', which is not a plain SQL identifier`);
|
|
62
|
-
}
|
|
63
|
-
return value;
|
|
64
|
-
}
|
|
54
|
+
const assertIdentifier = (kind, value, where) => assertSqlIdentifier('list', kind, value, where);
|
|
65
55
|
/** `@acme/vertical` → `acme_vertical`: an id is not an identifier, an index name needs one. */
|
|
66
56
|
function slug(value) {
|
|
67
57
|
return value
|
|
@@ -116,9 +106,12 @@ export class FilterNotDeclared extends Error {
|
|
|
116
106
|
* declaration the author believes is live that silently is not produces a list
|
|
117
107
|
* that pages wrongly with no error anywhere.
|
|
118
108
|
*/
|
|
119
|
-
export function listIndexPlans(moduleId, lists
|
|
109
|
+
export function listIndexPlans(moduleId, lists,
|
|
110
|
+
/** The SAME module's archive/trash declarations (#119) — its table, its columns. */
|
|
111
|
+
entityStates) {
|
|
120
112
|
if (!lists?.length)
|
|
121
113
|
return [];
|
|
114
|
+
const states = new Map(entityStatePlans(moduleId, entityStates).map((p) => [p.entityType, stateColumnsOf(p)]));
|
|
122
115
|
const plans = [];
|
|
123
116
|
for (const decl of lists) {
|
|
124
117
|
const where = `${moduleId} lists['${decl.entityType}']`;
|
|
@@ -147,6 +140,7 @@ export function listIndexPlans(moduleId, lists) {
|
|
|
147
140
|
sortable,
|
|
148
141
|
filterable,
|
|
149
142
|
indexStem: `${LIST_INDEX_PREFIX}${slug(moduleId)}_${slug(decl.entityType)}`,
|
|
143
|
+
...(states.has(decl.entityType) ? { states: states.get(decl.entityType) } : {}),
|
|
150
144
|
});
|
|
151
145
|
}
|
|
152
146
|
return plans;
|
|
@@ -175,7 +169,13 @@ export function listIndexColumns(plan) {
|
|
|
175
169
|
// entity's primary key by construction (`primaryKeyOf` resolved it), and
|
|
176
170
|
// SQLite already indexes that. Emitting one would pay write amplification on
|
|
177
171
|
// every insert for a second copy of an index that exists.
|
|
178
|
-
|
|
172
|
+
//
|
|
173
|
+
// UNLESS the entity is archivable (#119): then every walk is narrowed to a view, and the
|
|
174
|
+
// primary key would walk past every archived row to find the active ones — the archive is
|
|
175
|
+
// exactly the part of the table that grows without bound. A partial index per view is
|
|
176
|
+
// the fix, and it costs no more to write than the one full index it replaces: each row
|
|
177
|
+
// sits in exactly one view, so it is entered in exactly one of them.
|
|
178
|
+
if (walk.length > 1 || plan.states) {
|
|
179
179
|
out.push({ name: `${plan.indexStem}_${slug(sort)}`, columns: walk });
|
|
180
180
|
}
|
|
181
181
|
for (const filter of plan.filterable) {
|
|
@@ -187,7 +187,16 @@ export function listIndexColumns(plan) {
|
|
|
187
187
|
});
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
|
-
|
|
190
|
+
if (!plan.states)
|
|
191
|
+
return out;
|
|
192
|
+
// One partial index per view. The ACTIVE one keeps the name the full index had, so a scope
|
|
193
|
+
// that had the full index has it replaced rather than kept beside the partial one.
|
|
194
|
+
const states = plan.states;
|
|
195
|
+
return out.flatMap((idx) => viewsOf(states).map((view) => ({
|
|
196
|
+
name: view === 'active' ? idx.name : `${idx.name}_${view}`,
|
|
197
|
+
columns: idx.columns,
|
|
198
|
+
where: entityStateWhere(plan.entityType, states, view),
|
|
199
|
+
})));
|
|
191
200
|
}
|
|
192
201
|
/**
|
|
193
202
|
* The DDL for one plan's indexes.
|
|
@@ -198,12 +207,18 @@ export function listIndexColumns(plan) {
|
|
|
198
207
|
* old ones. An index is derived data; nothing is lost by dropping it.
|
|
199
208
|
*/
|
|
200
209
|
export function listIndexDdl(plan) {
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
210
|
+
return listIndexObjects(plan)
|
|
211
|
+
.flatMap((idx) => [`DROP INDEX IF EXISTS ${idx.name};`, `${idx.sql};`])
|
|
212
|
+
.join('\n');
|
|
213
|
+
}
|
|
214
|
+
/** The plan's indexes, each with its CREATE statement — what `listIndexDdl` runs. */
|
|
215
|
+
export function listIndexObjects(plan) {
|
|
216
|
+
return listIndexColumns(plan).map((idx) => ({
|
|
217
|
+
name: idx.name,
|
|
218
|
+
type: 'index',
|
|
219
|
+
table: plan.table,
|
|
220
|
+
sql: `CREATE INDEX ${idx.name} ON ${plan.table} (${idx.columns.join(', ')})${idx.where ? ` WHERE ${idx.where}` : ''}`,
|
|
221
|
+
}));
|
|
207
222
|
}
|
|
208
223
|
/**
|
|
209
224
|
* The migrations that provision a module's declared list indexes, journaled like
|
|
@@ -218,12 +233,19 @@ export function listIndexDdl(plan) {
|
|
|
218
233
|
* Appended AFTER the module's own migrations by the adapter, which is what makes
|
|
219
234
|
* the table exist by the time `CREATE INDEX` names it.
|
|
220
235
|
*/
|
|
221
|
-
export function listIndexMigrations(moduleId, lists) {
|
|
222
|
-
return listIndexPlans(moduleId, lists).map((plan) => ({
|
|
223
|
-
version:
|
|
236
|
+
export function listIndexMigrations(moduleId, lists, entityStates) {
|
|
237
|
+
return listIndexPlans(moduleId, lists, entityStates).map((plan) => ({
|
|
238
|
+
version: listIndexVersion(plan),
|
|
224
239
|
sql: listIndexDdl(plan),
|
|
225
240
|
}));
|
|
226
241
|
}
|
|
242
|
+
/**
|
|
243
|
+
* One plan's migration version. The views are part of the declaration the DDL depends on
|
|
244
|
+
* (#119): declaring a trash makes every index partial, so the version moves and the indexes
|
|
245
|
+
* are rebuilt.
|
|
246
|
+
*/
|
|
247
|
+
export const listIndexVersion = (plan) => `list/${plan.entityType}:${plan.sortable.join('+')}:${plan.filterable.join('+')}` +
|
|
248
|
+
(plan.states ? `:${viewsOf(plan.states).join('+')}` : '');
|
|
227
249
|
/**
|
|
228
250
|
* Index the plans by entity type for a whole scope, refusing an ambiguity — the
|
|
229
251
|
* same refusal `searchPlansByEntityType` makes, because `ctx.page('customer', …)`
|
|
@@ -233,7 +255,7 @@ export function listIndexMigrations(moduleId, lists) {
|
|
|
233
255
|
export function listPlansByEntityType(modules) {
|
|
234
256
|
const byType = new Map();
|
|
235
257
|
for (const mod of modules) {
|
|
236
|
-
for (const plan of listIndexPlans(mod.id, mod.lists)) {
|
|
258
|
+
for (const plan of listIndexPlans(mod.id, mod.lists, mod.entityStates)) {
|
|
237
259
|
const existing = byType.get(plan.entityType);
|
|
238
260
|
if (existing) {
|
|
239
261
|
throw new Error(`list: '${plan.entityType}' declares a paged list in both '${existing.moduleId}' and ` +
|
|
@@ -286,22 +308,31 @@ export class CursorMismatch extends SubstratError {
|
|
|
286
308
|
* minted exactly that legacy cursor (#2018 review).
|
|
287
309
|
*
|
|
288
310
|
* `id` is present exactly when the walk sorts by something other than the id itself.
|
|
311
|
+
*
|
|
312
|
+
* `view` (#119) names an archivable entity's view when it is not `active`. A position in the
|
|
313
|
+
* active rows means nothing among the archived ones: replayed there, `id > ?` silently skips
|
|
314
|
+
* every archived row before it. Absent means active, so every cursor minted before it — and
|
|
315
|
+
* every active one since — reads the same, and a change of view is a `cursor_restart`.
|
|
289
316
|
*/
|
|
290
317
|
const cursorEnvelope = z.strictObject({
|
|
291
318
|
v: z.literal(1),
|
|
292
319
|
order: z.enum(['asc', 'desc']),
|
|
293
|
-
sort: z.string().regex(
|
|
320
|
+
sort: z.string().regex(SQL_IDENTIFIER),
|
|
294
321
|
value: z.string(),
|
|
295
322
|
id: z.string().optional(),
|
|
323
|
+
view: z.enum(['archived', 'trashed']).optional(),
|
|
296
324
|
});
|
|
297
325
|
/** Build the cursor a row hands to the next page — the walk that minted it, and where. */
|
|
298
|
-
export function cursorOf(row, sortColumn, idColumn, order
|
|
326
|
+
export function cursorOf(row, sortColumn, idColumn, order,
|
|
327
|
+
/** The walk's view (#119). `active`, or unset, is left out of the envelope. */
|
|
328
|
+
view) {
|
|
299
329
|
const envelope = {
|
|
300
330
|
v: 1,
|
|
301
331
|
order,
|
|
302
332
|
sort: sortColumn,
|
|
303
333
|
value: String(row[sortColumn] ?? ''),
|
|
304
334
|
...(sortColumn === idColumn ? {} : { id: String(row[idColumn] ?? '') }),
|
|
335
|
+
...(view && view !== 'active' ? { view } : {}),
|
|
305
336
|
};
|
|
306
337
|
return toBase64url(new TextEncoder().encode(JSON.stringify(envelope)));
|
|
307
338
|
}
|
|
@@ -317,6 +348,15 @@ function envelopeOf(cursor) {
|
|
|
317
348
|
return undefined;
|
|
318
349
|
}
|
|
319
350
|
}
|
|
351
|
+
/** Migration gate for filtered walks: their old input was a plain ctx.page cursor. */
|
|
352
|
+
export function isPlainPageCursor(cursor) {
|
|
353
|
+
if (envelopeOf(cursor))
|
|
354
|
+
return true;
|
|
355
|
+
if (ULID_PATTERN.test(cursor))
|
|
356
|
+
return true;
|
|
357
|
+
const at = cursor.lastIndexOf('|');
|
|
358
|
+
return at >= 0 && ULID_PATTERN.test(cursor.slice(at + 1));
|
|
359
|
+
}
|
|
320
360
|
/**
|
|
321
361
|
* A pre-#2001 cursor, recognised only by its exact old shape: `<value>|<id>` with the
|
|
322
362
|
* id a ULID, or — for a walk sorted by the id itself — the bare ULID. Split on the LAST
|
|
@@ -340,9 +380,14 @@ function legacyPositionOf(cursor, plan, sortColumn) {
|
|
|
340
380
|
* is where it would replay silently: under a newly honoured `desc` default above all.
|
|
341
381
|
* Anything that is neither is refused too. Every refusal is the same `cursor_restart`.
|
|
342
382
|
*/
|
|
343
|
-
function positionIn(cursor, plan, sortColumn, order) {
|
|
383
|
+
function positionIn(cursor, plan, sortColumn, order, view) {
|
|
344
384
|
const envelope = envelopeOf(cursor);
|
|
345
385
|
if (envelope) {
|
|
386
|
+
const minted = envelope.view ?? 'active';
|
|
387
|
+
if (minted !== view) {
|
|
388
|
+
throw new CursorMismatch(`list: this cursor continues the ${minted} rows, and this request asks for the ${view} ones — ` +
|
|
389
|
+
'restart paging from the first page, without a cursor');
|
|
390
|
+
}
|
|
346
391
|
if (envelope.order !== order || envelope.sort !== sortColumn) {
|
|
347
392
|
throw new CursorMismatch(`list: this cursor continues a walk by '${envelope.sort}' ${envelope.order}, and this request ` +
|
|
348
393
|
`asks for '${sortColumn}' ${order} — keep the sort and order the first page was read with, ` +
|
|
@@ -354,7 +399,8 @@ function positionIn(cursor, plan, sortColumn, order) {
|
|
|
354
399
|
return { value: envelope.value, id: envelope.id };
|
|
355
400
|
}
|
|
356
401
|
const legacy = legacyPositionOf(cursor, plan, sortColumn);
|
|
357
|
-
|
|
402
|
+
// Every legacy cursor predates the views, so it was minted over the active rows (#119).
|
|
403
|
+
if (legacy && order === 'asc' && sortColumn === plan.sortable[0] && view === 'active')
|
|
358
404
|
return legacy;
|
|
359
405
|
throw new CursorMismatch(legacy
|
|
360
406
|
? `list: this cursor predates the walk it is replayed in ('${sortColumn}' ${order}) — ` +
|
|
@@ -380,6 +426,11 @@ export function listQuery(plan, params) {
|
|
|
380
426
|
const filters = Object.entries(params.filters ?? {}).filter(([, v]) => v !== undefined);
|
|
381
427
|
const where = [];
|
|
382
428
|
const args = [];
|
|
429
|
+
// The view first, in the exact words the partial index was created with — SQLite uses a
|
|
430
|
+
// partial index only when the query's WHERE carries its terms.
|
|
431
|
+
const view = entityStateWhere(plan.entityType, plan.states, params.view);
|
|
432
|
+
if (view)
|
|
433
|
+
where.push(view);
|
|
383
434
|
for (const [column, value] of filters) {
|
|
384
435
|
if (!plan.filterable.includes(column)) {
|
|
385
436
|
throw new FilterNotDeclared(plan.entityType, column, plan.filterable);
|
|
@@ -425,7 +476,7 @@ export function listQuery(plan, params) {
|
|
|
425
476
|
const countParams = [...args];
|
|
426
477
|
const cmp = order === 'asc' ? '>' : '<';
|
|
427
478
|
if (params.cursor !== undefined && params.cursor !== '') {
|
|
428
|
-
const { value, id } = positionIn(params.cursor, plan, sortColumn, order);
|
|
479
|
+
const { value, id } = positionIn(params.cursor, plan, sortColumn, order, params.view ?? 'active');
|
|
429
480
|
if (id === undefined) {
|
|
430
481
|
where.push(`${sortColumn} ${cmp} ?`);
|
|
431
482
|
args.push(value);
|
|
@@ -451,6 +502,7 @@ export function listQuery(plan, params) {
|
|
|
451
502
|
countParams,
|
|
452
503
|
sortColumn,
|
|
453
504
|
order,
|
|
505
|
+
view: params.view ?? 'active',
|
|
454
506
|
};
|
|
455
507
|
}
|
|
456
508
|
//# sourceMappingURL=list-index.js.map
|
package/dist/list-index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-index.js","sourceRoot":"","sources":["../src/list-index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,OAAO,EAAE,mBAAmB,EAAE,aAAa,EAAE,YAAY,EAAE,CAAC,EAAE,MAAM,yBAAyB,CAAC;AAC9F,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAqC5D,mDAAmD;AACnD,MAAM,CAAC,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;AAEnD,6DAA6D;AAC7D,MAAM,UAAU,eAAe,CAAC,IAAY;IAC1C,OAAO,IAAI,CAAC,UAAU,CAAC,iBAAiB,CAAC,CAAC;AAC5C,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,GAAG,0BAA0B,CAAC;AAE9C,SAAS,gBAAgB,CAAC,IAAY,EAAE,KAAa,EAAE,KAAa;IAClE,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC;QAC5B,MAAM,IAAI,KAAK,CAAC,SAAS,KAAK,UAAU,IAAI,KAAK,KAAK,w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EAAsE;YACtE,0DAA0D;YAC1D,KAAK,CAAC,IAAI,CAAC,IAAI,UAAU,IAAI,GAAG,UAAU,UAAU,YAAY,IAAI,CAAC,QAAQ,IAAI,GAAG,MAAM,CAAC,CAAC;YAC5F,IAAI,CAAC,IAAI,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE,CAAC,CAAC;QAC9B,CAAC;IACH,CAAC;IACD,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,UAAU,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;IACxE,MAAM,SAAS,GAAG,KAAK,KAAK,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC;IACnD,MAAM,OAAO,GACX,UAAU,KAAK,IAAI,CAAC,QAAQ;QAC1B,CAAC,CAAC,aAAa,UAAU,IAAI,SAAS,EAAE;QACxC,CAAC,CAAC,aAAa,UAAU,IAAI,SAAS,KAAK,IAAI,CAAC,QAAQ,IAAI,SAAS,EAAE,CAAC;IAC5E,OAAO;QACL,GAAG,EAAE,iBAAiB,IAAI,CAAC,KAAK,GAAG,WAAW,GAAG,OAAO,UAAU;QAClE,MAAM,EAAE,CAAC,GAAG,IAAI,EAAE,MAAM,CAAC,KAAK,CAAC;QAC/B,QAAQ,EAAE,6BAA6B,IAAI,CAAC,KAAK,GAAG,UAAU,EAAE;QAChE,WAAW;QACX,UAAU;QACV,KAAK;QACL,IAAI,EAAE,MAAM,CAAC,IAAI,IAAI,QAAQ;KAC9B,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import type { Connection } from '@substrat-run/contracts';
|
|
2
|
+
import type { ScopeHost } from './scope-host.js';
|
|
3
|
+
/**
|
|
4
|
+
* A connection that can send mail as an address the tenant owns (#2098) — a tenant's own
|
|
5
|
+
* mailbox behind the platform's email relay.
|
|
6
|
+
*
|
|
7
|
+
* A vertical says what to send and from which address; the platform decides who sends it.
|
|
8
|
+
* With no `from` the relay sends as the platform's own address, as it always has. With one,
|
|
9
|
+
* it looks for a live connection of the tenant's whose sender says it may send as that
|
|
10
|
+
* address, and hands the message to it. So Microsoft 365, Google Workspace or a tenant's own
|
|
11
|
+
* Resend account is a connector implementing this, and a vertical never branches on which.
|
|
12
|
+
*
|
|
13
|
+
* **Shaped like a connection inspector, not a dispatch.** The relay runs top-level on the
|
|
14
|
+
* control plane, not inside a delivery for a scope, so the sender is handed the host and the
|
|
15
|
+
* connection's row and opens its own credential — the same way `probe(host, row)` does —
|
|
16
|
+
* rather than being handed a connection the relay opened for it.
|
|
17
|
+
*/
|
|
18
|
+
export interface MailSender {
|
|
19
|
+
/**
|
|
20
|
+
* The addresses this connection may send as. Compared case-insensitively by the relay.
|
|
21
|
+
*
|
|
22
|
+
* Asked on every send that names a `from`, so it should answer from what the connection
|
|
23
|
+
* already holds (its configuration, its secret) rather than a provider round trip.
|
|
24
|
+
*/
|
|
25
|
+
senders(host: ScopeHost, connection: Connection): Promise<readonly string[]>;
|
|
26
|
+
/**
|
|
27
|
+
* Send one message as `mail.from.email`, which `senders` has already admitted.
|
|
28
|
+
*
|
|
29
|
+
* A failure should throw an error carrying the provider's numeric `status`, and for a
|
|
30
|
+
* throttle its `Retry-After` in seconds as `retryAfter` (#2102): the platform retries a
|
|
31
|
+
* send whose status is 429 or 5xx (or absent) and refuses one whose status is any other 4xx,
|
|
32
|
+
* reading both structurally, so a sender that rewords an error must keep the two fields.
|
|
33
|
+
*/
|
|
34
|
+
send(host: ScopeHost, connection: Connection, mail: OutboundMail): Promise<MailSendResult>;
|
|
35
|
+
}
|
|
36
|
+
/** An address, optionally with a display name. */
|
|
37
|
+
export interface MailAddress {
|
|
38
|
+
email: string;
|
|
39
|
+
name?: string;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* One file sent with a message, as bytes. The relay reads it from the scope's attachments by
|
|
43
|
+
* id, as the sending connection, before the sender sees it — so a sender never needs a door
|
|
44
|
+
* into the scope, and reads nothing its connection was not granted.
|
|
45
|
+
*/
|
|
46
|
+
export interface OutboundMailAttachment {
|
|
47
|
+
filename: string;
|
|
48
|
+
contentType: string;
|
|
49
|
+
content: Uint8Array;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* A message after the relay has validated it: recipients are a list, both parts are
|
|
53
|
+
* present, attachments are bytes. Structurally the email adapter's prepared message plus
|
|
54
|
+
* attachments; declared here because connectors depend on the kernel and not on the adapter.
|
|
55
|
+
*/
|
|
56
|
+
export interface OutboundMail {
|
|
57
|
+
from: MailAddress;
|
|
58
|
+
to: MailAddress[];
|
|
59
|
+
replyTo?: MailAddress;
|
|
60
|
+
subject: string;
|
|
61
|
+
html: string;
|
|
62
|
+
text: string;
|
|
63
|
+
headers?: Record<string, string>;
|
|
64
|
+
attachments: OutboundMailAttachment[];
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* The immediate outcome, per recipient, on the email adapter's neutral names: `delivered`
|
|
68
|
+
* (accepted by the recipient's server), `queued` (accepted, still in flight) and `bounced`
|
|
69
|
+
* (refused for good). A sender that only learns "accepted" reports every recipient `queued`.
|
|
70
|
+
*/
|
|
71
|
+
export interface MailSendResult {
|
|
72
|
+
delivered: string[];
|
|
73
|
+
queued: string[];
|
|
74
|
+
bounced: string[];
|
|
75
|
+
/** The provider's id for the message, when it returns one (#2102). Graph's `sendMail` does not. */
|
|
76
|
+
messageId?: string;
|
|
77
|
+
}
|
|
78
|
+
//# sourceMappingURL=mail-sender.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mail-sender.d.ts","sourceRoot":"","sources":["../src/mail-sender.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAEjD;;;;;;;;;;;;;;GAcG;AACH,MAAM,WAAW,UAAU;IACzB;;;;;OAKG;IACH,OAAO,CAAC,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,UAAU,GAAG,OAAO,CAAC,SAAS,MAAM,EAAE,CAAC,CAAC;IAC7E;;;;;;;OAOG;IACH,IAAI,CAAC,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,UAAU,EAAE,IAAI,EAAE,YAAY,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;CAC5F;AAED,kDAAkD;AAClD,MAAM,WAAW,WAAW;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED;;;;GAIG;AACH,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,UAAU,CAAC;CACrB;AAED;;;;GAIG;AACH,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,WAAW,CAAC;IAClB,EAAE,EAAE,WAAW,EAAE,CAAC;IAClB,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,WAAW,EAAE,sBAAsB,EAAE,CAAC;CACvC;AAED;;;;GAIG;AACH,MAAM,WAAW,cAAc;IAC7B,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,mGAAmG;IACnG,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mail-sender.js","sourceRoot":"","sources":["../src/mail-sender.ts"],"names":[],"mappings":""}
|
|
@@ -1,52 +1,5 @@
|
|
|
1
1
|
import { z, type EntityRef, type PlatformActorId } from '@substrat-run/contracts';
|
|
2
2
|
import { type ExecutorRetryPolicy, type ScopeHost } from './scope-host.js';
|
|
3
|
-
/**
|
|
4
|
-
* The membership executor (K-22 §4.2, membership.md §4.2; #1184) — the out-of-band half of
|
|
5
|
-
* joining and leaving, written once so a host mounts it instead of hand-rolling the effect.
|
|
6
|
-
*
|
|
7
|
-
* Module code asks in its own transaction and this effects after commit, through `HostAdmin`:
|
|
8
|
-
* an invite engine's accept emits `member.add-requested`; a vertical's removal emits
|
|
9
|
-
* `member.remove-requested`. A rolled-back operation leaves no event and nothing to effect.
|
|
10
|
-
* Both are driven inline by the emitting call, with the outbox and `_substrat_deliveries` as
|
|
11
|
-
* the retry backstop, so the common case completes inside the request.
|
|
12
|
-
*
|
|
13
|
-
* **What it effects: a tenant-level role, and nothing else.** An add assigns the invited role
|
|
14
|
-
* at the tenant node; a removal unassigns it. Neither joins nor leaves an org, although both
|
|
15
|
-
* payloads name one (the invites engine keys its invitations by org): what an org confers
|
|
16
|
-
* includes grants in each scope's own store, which no directory unit can bound, so making
|
|
17
|
-
* someone a member of an org is authority this seam does not carry.
|
|
18
|
-
*
|
|
19
|
-
* **Authority.** Every payload field is module-written, so none of them is authority.
|
|
20
|
-
*
|
|
21
|
-
* - An ADD is bounded by the inviter: the kernel-stamped `actor` of the invitation's own
|
|
22
|
-
* `invites.sent` event, asked through the K-21 set comparison at the tenant node. Asked
|
|
23
|
-
* twice: early, to refuse cheaply, and again inside the directory unit that writes the role
|
|
24
|
-
* (`applyMembership`), so a demotion, a grant lost or a role widened in between is not
|
|
25
|
-
* written past. The joiner is the request's own actor, who must have made the invitation's
|
|
26
|
-
* first acceptance, and the request must be the first one naming that invitation: one
|
|
27
|
-
* invitation, one join. The most a module can do is make the principal who actually invoked
|
|
28
|
-
* it look like the sender — the same delegation bound `ctx.grant` has.
|
|
29
|
-
* - A REMOVE is bounded by the remover, the request's own actor (§5.1: removal takes the
|
|
30
|
-
* same bound, or a junior admin could strip a role they could not have granted) — asked the
|
|
31
|
-
* same two ways, so a remover demoted in between removes nobody.
|
|
32
|
-
*
|
|
33
|
-
* **Removal wins.** An add is refused when the joiner was removed after it was requested: by a
|
|
34
|
-
* later `member.remove-requested` on the same membership (ordered by outbox id), or by any
|
|
35
|
-
* tenant-level removal at all — staff's included, and a no-op one — which raises the person's
|
|
36
|
-
* removal fence in the directory unit that revokes. The add's own unit reads the fence, and a
|
|
37
|
-
* fence at or after `occurredAt - MEMBERSHIP_REMOVAL_SKEW_MS` refuses it.
|
|
38
|
-
*
|
|
39
|
-
* A refusal is terminal (`refuseDelivery`): journaled with its reason, never retried, listed
|
|
40
|
-
* by `executorDeadLetters`, and reported to the emitting call through `onExecutorOutcomes`.
|
|
41
|
-
*
|
|
42
|
-
* **The trail.** Admin rows are written by `actor`, the platform identity that executed them,
|
|
43
|
-
* `onBehalfOf` (#977) the person whose authority bounded them, and with `causedBy` = the event
|
|
44
|
-
* id: the correlation id that joins the scope's half of the trail to the directory's. A
|
|
45
|
-
* removal that took nothing writes no row (K-21), but still raises the fence.
|
|
46
|
-
*
|
|
47
|
-
* **Idempotent.** A delivered event never reaches its handler again. A crash between the
|
|
48
|
-
* effect and its journal row re-runs the handler, and every write it makes is idempotent.
|
|
49
|
-
*/
|
|
50
3
|
/** What the add path consumes, and the version it reads. */
|
|
51
4
|
export declare const MEMBER_ADD_REQUESTED = "member.add-requested";
|
|
52
5
|
/** What the remove path consumes, and the version it reads. */
|
|
@@ -82,6 +35,13 @@ export interface MembershipExecutorOptions {
|
|
|
82
35
|
* A scope role has its own atomic check-and-grant: `assignScopeRoleBounded`.
|
|
83
36
|
*/
|
|
84
37
|
level?: 'tenant';
|
|
38
|
+
/**
|
|
39
|
+
* What happens to the org a request names (#2047). `'ignore'`, the default: nothing — the org
|
|
40
|
+
* is the vertical's own vocabulary, and only the role is effected. `'join'`: an add joins it
|
|
41
|
+
* and a removal takes the person out of it, beside the role and in the same unit, bounded by
|
|
42
|
+
* the inviter's or remover's own live membership of it (`MembershipChange.orgId`).
|
|
43
|
+
*/
|
|
44
|
+
orgs?: 'ignore' | 'join';
|
|
85
45
|
retry?: ExecutorRetryPolicy;
|
|
86
46
|
}
|
|
87
47
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"membership-executor.d.ts","sourceRoot":"","sources":["../src/membership-executor.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,CAAC,EAED,KAAK,SAAS,
|
|
1
|
+
{"version":3,"file":"membership-executor.d.ts","sourceRoot":"","sources":["../src/membership-executor.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,CAAC,EAED,KAAK,SAAS,EAGd,KAAK,eAAe,EAErB,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EACL,KAAK,mBAAmB,EAIxB,KAAK,SAAS,EACf,MAAM,iBAAiB,CAAC;AA2DzB,4DAA4D;AAC5D,eAAO,MAAM,oBAAoB,yBAAyB,CAAC;AAC3D,+DAA+D;AAC/D,eAAO,MAAM,uBAAuB,4BAA4B,CAAC;AAEjE,oGAAoG;AACpG,eAAO,MAAM,sBAAsB,eAAe,CAAC;AACnD,wEAAwE;AACxE,eAAO,MAAM,0BAA0B,QAAQ,MAAM,KAA4B,MAAwB,CAAC;AAE1G,+FAA+F;AAC/F,eAAO,MAAM,gBAAgB,cAAe,MAAM,KAAG,SAAgE,CAAC;AAWtH;;;;GAIG;AACH,eAAO,MAAM,4BAA4B;;;;;iBAKvC,CAAC;AACH,MAAM,MAAM,4BAA4B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC;AAMxF,MAAM,WAAW,yBAAyB;IACxC,8FAA8F;IAC9F,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,gFAAgF;IAChF,KAAK,EAAE,eAAe,CAAC;IACvB;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,QAAQ,CAAC;IACjB;;;;;OAKG;IACH,IAAI,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;IACzB,KAAK,CAAC,EAAE,mBAAmB,CAAC;CAC7B;AAED;;;;;;GAMG;AACH,eAAO,MAAM,0BAA0B,QAAa,CAAC;AAErD,8FAA8F;AAC9F,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,SAAS,EAAE,OAAO,EAAE,yBAAyB,GAAG,IAAI,CAsEpG"}
|