latticesql 3.1.0 → 3.2.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 +4 -0
- package/dist/cli.js +2174 -1016
- package/dist/index.cjs +393 -190
- package/dist/index.d.cts +15 -20
- package/dist/index.d.ts +15 -20
- package/dist/index.js +393 -190
- package/docs/api-reference.md +1370 -0
- package/docs/architecture.md +331 -0
- package/docs/assistant.md +138 -0
- package/docs/cli.md +515 -0
- package/docs/cloud.md +675 -0
- package/docs/collaboration.md +85 -0
- package/docs/configuration.md +416 -0
- package/docs/entity-context.md +510 -0
- package/docs/examples/agent-system.md +313 -0
- package/docs/examples/cms.md +366 -0
- package/docs/examples/ticket-tracker.md +313 -0
- package/docs/migrations.md +272 -0
- package/docs/templates.md +338 -0
- package/docs/workspaces.md +81 -0
- package/package.json +3 -2
package/dist/index.d.cts
CHANGED
|
@@ -1798,18 +1798,26 @@ interface RenderOptions {
|
|
|
1798
1798
|
declare class ProgressThrottle {
|
|
1799
1799
|
private readonly cb;
|
|
1800
1800
|
private readonly windowMs;
|
|
1801
|
-
|
|
1801
|
+
/**
|
|
1802
|
+
* Last passthrough time, keyed per table (`event.table`, or `''` for the
|
|
1803
|
+
* table-less `done`/`error` lifecycle events). Per-table — not a single shared
|
|
1804
|
+
* clock — so when tables render CONCURRENTLY each one keeps its own ~5/sec
|
|
1805
|
+
* budget: a fast table can't consume the window and starve a slow table's
|
|
1806
|
+
* progress. `force` (table-start) resets only that table's budget.
|
|
1807
|
+
*/
|
|
1808
|
+
private readonly lastEmit;
|
|
1802
1809
|
constructor(cb: RenderProgressCallback | undefined, windowMs?: number);
|
|
1803
1810
|
/**
|
|
1804
|
-
* Emit a `table-progress` event, but only if the window since
|
|
1805
|
-
* passthrough has elapsed. Dropped events are simply not delivered — the
|
|
1806
|
-
* one that survives carries the latest running count.
|
|
1811
|
+
* Emit a `table-progress` event, but only if the window since this table's
|
|
1812
|
+
* last passthrough has elapsed. Dropped events are simply not delivered — the
|
|
1813
|
+
* next one that survives carries the latest running count.
|
|
1807
1814
|
*/
|
|
1808
1815
|
tick(event: RenderProgress): void;
|
|
1809
1816
|
/**
|
|
1810
|
-
* Emit a lifecycle event immediately and reset
|
|
1811
|
-
* `table-start`, `table-done`, `done`, and `error` — none of which
|
|
1812
|
-
* ever be dropped. Resetting on `table-start` gives each table a clean
|
|
1817
|
+
* Emit a lifecycle event immediately and reset this table's throttle window.
|
|
1818
|
+
* Use for `table-start`, `table-done`, `done`, and `error` — none of which
|
|
1819
|
+
* should ever be dropped. Resetting on `table-start` gives each table a clean
|
|
1820
|
+
* budget.
|
|
1813
1821
|
*/
|
|
1814
1822
|
force(event: RenderProgress): void;
|
|
1815
1823
|
}
|
|
@@ -4337,19 +4345,6 @@ declare class FoldCache {
|
|
|
4337
4345
|
get size(): number;
|
|
4338
4346
|
}
|
|
4339
4347
|
|
|
4340
|
-
/**
|
|
4341
|
-
* Turn a Postgres database into a secured Lattice cloud, in place: install the
|
|
4342
|
-
* RLS bootstrap + the observation substrate, then for every registered user
|
|
4343
|
-
* table stamp the current role as owner of the existing rows and force RLS (plus
|
|
4344
|
-
* a cell-masking view for any audience columns). Idempotent and additive — safe
|
|
4345
|
-
* to run on a fresh migration target OR on an already-populated Postgres that
|
|
4346
|
-
* isn't a cloud yet (the "secure this cloud" cutover). No-op on SQLite.
|
|
4347
|
-
*
|
|
4348
|
-
* Must run as a role that owns the tables and can create roles (a cloud
|
|
4349
|
-
* owner / DBA). `backfillOwnership` runs BEFORE `enableRlsForTable` so a
|
|
4350
|
-
* non-superuser owner can still SELECT every row to stamp it before FORCE RLS
|
|
4351
|
-
* filters the table to rows it already owns.
|
|
4352
|
-
*/
|
|
4353
4348
|
declare function secureCloud(db: Lattice): Promise<void>;
|
|
4354
4349
|
|
|
4355
4350
|
/**
|
package/dist/index.d.ts
CHANGED
|
@@ -1798,18 +1798,26 @@ interface RenderOptions {
|
|
|
1798
1798
|
declare class ProgressThrottle {
|
|
1799
1799
|
private readonly cb;
|
|
1800
1800
|
private readonly windowMs;
|
|
1801
|
-
|
|
1801
|
+
/**
|
|
1802
|
+
* Last passthrough time, keyed per table (`event.table`, or `''` for the
|
|
1803
|
+
* table-less `done`/`error` lifecycle events). Per-table — not a single shared
|
|
1804
|
+
* clock — so when tables render CONCURRENTLY each one keeps its own ~5/sec
|
|
1805
|
+
* budget: a fast table can't consume the window and starve a slow table's
|
|
1806
|
+
* progress. `force` (table-start) resets only that table's budget.
|
|
1807
|
+
*/
|
|
1808
|
+
private readonly lastEmit;
|
|
1802
1809
|
constructor(cb: RenderProgressCallback | undefined, windowMs?: number);
|
|
1803
1810
|
/**
|
|
1804
|
-
* Emit a `table-progress` event, but only if the window since
|
|
1805
|
-
* passthrough has elapsed. Dropped events are simply not delivered — the
|
|
1806
|
-
* one that survives carries the latest running count.
|
|
1811
|
+
* Emit a `table-progress` event, but only if the window since this table's
|
|
1812
|
+
* last passthrough has elapsed. Dropped events are simply not delivered — the
|
|
1813
|
+
* next one that survives carries the latest running count.
|
|
1807
1814
|
*/
|
|
1808
1815
|
tick(event: RenderProgress): void;
|
|
1809
1816
|
/**
|
|
1810
|
-
* Emit a lifecycle event immediately and reset
|
|
1811
|
-
* `table-start`, `table-done`, `done`, and `error` — none of which
|
|
1812
|
-
* ever be dropped. Resetting on `table-start` gives each table a clean
|
|
1817
|
+
* Emit a lifecycle event immediately and reset this table's throttle window.
|
|
1818
|
+
* Use for `table-start`, `table-done`, `done`, and `error` — none of which
|
|
1819
|
+
* should ever be dropped. Resetting on `table-start` gives each table a clean
|
|
1820
|
+
* budget.
|
|
1813
1821
|
*/
|
|
1814
1822
|
force(event: RenderProgress): void;
|
|
1815
1823
|
}
|
|
@@ -4337,19 +4345,6 @@ declare class FoldCache {
|
|
|
4337
4345
|
get size(): number;
|
|
4338
4346
|
}
|
|
4339
4347
|
|
|
4340
|
-
/**
|
|
4341
|
-
* Turn a Postgres database into a secured Lattice cloud, in place: install the
|
|
4342
|
-
* RLS bootstrap + the observation substrate, then for every registered user
|
|
4343
|
-
* table stamp the current role as owner of the existing rows and force RLS (plus
|
|
4344
|
-
* a cell-masking view for any audience columns). Idempotent and additive — safe
|
|
4345
|
-
* to run on a fresh migration target OR on an already-populated Postgres that
|
|
4346
|
-
* isn't a cloud yet (the "secure this cloud" cutover). No-op on SQLite.
|
|
4347
|
-
*
|
|
4348
|
-
* Must run as a role that owns the tables and can create roles (a cloud
|
|
4349
|
-
* owner / DBA). `backfillOwnership` runs BEFORE `enableRlsForTable` so a
|
|
4350
|
-
* non-superuser owner can still SELECT every row to stamp it before FORCE RLS
|
|
4351
|
-
* filters the table to rows it already owns.
|
|
4352
|
-
*/
|
|
4353
4348
|
declare function secureCloud(db: Lattice): Promise<void>;
|
|
4354
4349
|
|
|
4355
4350
|
/**
|