@klum-db/lobby 0.2.0-pre.33 → 0.4.0-pre.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/README.md +22 -1
- package/dist/bin/klum.cjs.map +1 -1
- package/dist/bin/klum.d.cts +2 -3
- package/dist/bin/klum.d.ts +2 -3
- package/dist/bin/klum.js.map +1 -1
- package/dist/index.cjs +106 -102
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -13
- package/dist/index.d.ts +12 -13
- package/dist/index.js +37 -35
- package/dist/index.js.map +1 -1
- package/dist/{vault-group-SfkQJ3CM.d.cts → vault-group-D0EC-D5c.d.cts} +5 -6
- package/dist/{vault-group-SfkQJ3CM.d.ts → vault-group-D0EC-D5c.d.ts} +5 -6
- package/package.json +15 -14
package/dist/index.d.cts
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import { Vault, SealingKeyProvider,
|
|
2
|
-
export { CustodyApi, DeedMarker, GrantCustodianOptions, LiberateOptions, LiberateResult, createDeedOwner, isDeedVault, liberateVault, loadDeedMarker } from '@noy-db/hub';
|
|
3
|
-
import { a as VaultTemplate, S as StateManagementVault, V as VaultGroup, b as SkippedVault, M as MergeCompartmentOptions, c as MergeReport, d as SurfaceDirection, e as SurfaceConflictPolicy, f as SurfaceRow, g as VaultGroupOptions } from './vault-group-
|
|
4
|
-
export { C as CapturedBlueprint, h as CrossVaultAggregation, i as CrossVaultDerivationContext, j as CrossVaultDerivationSpec, k as CrossVaultGroupedAggregation, G as CrossVaultGroupedRow, l as CrossVaultLiveAggregation, m as CrossVaultLiveQuery, D as DecryptedMergeOptions, n as DeploymentEvent, F as FanoutQueryOptions, o as FanoutResult, p as FederatedRetrieveHit, q as FederatedRetrieveOptions, r as FederatedRetrieveResult, s as FederationMeta, t as FieldAuthorityInputs, u as FieldAuthorityPolicy, v as FieldAuthorityPolicyMissingError, w as FieldAuthorityRule, x as FieldLevelDeferredError, y as GroupMeta, I as InsightAutoPushConfig, L as LiveQueryOptions, z as MergeConflict, A as MergeStrategy, B as MigrationStatusRow, R as RefreshInsightsResult, E as SchemaManifestRow, H as SchemaRolloutResult, J as ShardedCollection, K as ShardedGroupedQuery, N as ShardedQuery, O as ShardingConfig, P as SurfaceStatus, Q as VaultRegistryRow, T as mergeCompartment, U as mergeDecryptedRecords, W as resolveFieldAuthority, X as resolveRecordByFieldAuthority } from './vault-group-
|
|
1
|
+
import { Vault, SealingKeyProvider, Noydb } from '@noy-db/hub/cargo';
|
|
2
|
+
export { CrossShardJoinError, CustodyApi, DataResidencyError, DeedMarker, GrantCustodianOptions, LiberateOptions, LiberateResult, ReservedVaultNameError, ShardProvisioningError, UnknownShardError, VaultTemplateNotFoundError, createDeedOwner, isDeedVault, liberateVault, loadDeedMarker } from '@noy-db/hub/cargo';
|
|
3
|
+
import { a as VaultTemplate, S as StateManagementVault, V as VaultGroup, b as SkippedVault, M as MergeCompartmentOptions, c as MergeReport, d as SurfaceDirection, e as SurfaceConflictPolicy, f as SurfaceRow, g as VaultGroupOptions } from './vault-group-D0EC-D5c.cjs';
|
|
4
|
+
export { C as CapturedBlueprint, h as CrossVaultAggregation, i as CrossVaultDerivationContext, j as CrossVaultDerivationSpec, k as CrossVaultGroupedAggregation, G as CrossVaultGroupedRow, l as CrossVaultLiveAggregation, m as CrossVaultLiveQuery, D as DecryptedMergeOptions, n as DeploymentEvent, F as FanoutQueryOptions, o as FanoutResult, p as FederatedRetrieveHit, q as FederatedRetrieveOptions, r as FederatedRetrieveResult, s as FederationMeta, t as FieldAuthorityInputs, u as FieldAuthorityPolicy, v as FieldAuthorityPolicyMissingError, w as FieldAuthorityRule, x as FieldLevelDeferredError, y as GroupMeta, I as InsightAutoPushConfig, L as LiveQueryOptions, z as MergeConflict, A as MergeStrategy, B as MigrationStatusRow, R as RefreshInsightsResult, E as SchemaManifestRow, H as SchemaRolloutResult, J as ShardedCollection, K as ShardedGroupedQuery, N as ShardedQuery, O as ShardingConfig, P as SurfaceStatus, Q as VaultRegistryRow, T as mergeCompartment, U as mergeDecryptedRecords, W as resolveFieldAuthority, X as resolveRecordByFieldAuthority } from './vault-group-D0EC-D5c.cjs';
|
|
5
5
|
import { AsXlsxSheetOptions } from '@noy-db/as-xlsx';
|
|
6
6
|
export { MultiVaultDenormColumn, MultiVaultXlsxEntry, MultiVaultXlsxOptions } from '@noy-db/as-xlsx';
|
|
7
|
-
import { ExtractionPreview
|
|
8
|
-
import { Vault as Vault$1 } from '@noy-db/hub/kernel';
|
|
9
|
-
export { CrossShardJoinError, DataResidencyError, ReservedVaultNameError, ShardProvisioningError, UnknownShardError, VaultTemplateNotFoundError } from '@noy-db/hub/kernel';
|
|
7
|
+
import { ExtractionPreview } from '@noy-db/hub/bundle';
|
|
10
8
|
import { InspectableContainer } from '@noy-db/in-devtools';
|
|
9
|
+
import { Cover, WritePodOptions } from '@noy-db/hub/pod';
|
|
11
10
|
|
|
12
11
|
/**
|
|
13
12
|
* @klum-db/lobby interchange — cross-vault FK-closure extraction.
|
|
@@ -284,7 +283,7 @@ declare function meterGroup<T>(group: VaultGroup<T>, opts?: {
|
|
|
284
283
|
* that embeds N standard single-vault `.noydb` bundles plus an
|
|
285
284
|
* unencrypted, owner-curated **manifest**. The v1 single-vault format
|
|
286
285
|
* is untouched; each compartment is a complete v1 bundle, produced by
|
|
287
|
-
* `
|
|
286
|
+
* `writePod` and read by `readNoydbBundle`.
|
|
288
287
|
*
|
|
289
288
|
* Layout: magic 'NDBM'(4) · version(1) · reserved(1) · manifestLen(4 BE)
|
|
290
289
|
* · manifest JSON · concat(inner v1 bundles, in manifest order).
|
|
@@ -313,8 +312,8 @@ interface CompartmentManifest {
|
|
|
313
312
|
readonly name: string;
|
|
314
313
|
readonly count: number;
|
|
315
314
|
}[];
|
|
316
|
-
/** Inner bundle's owner-curated public envelope
|
|
317
|
-
readonly publicEnvelope?:
|
|
315
|
+
/** Inner bundle's owner-curated cover (né public envelope — manifest key is this repo's wire). Opt-in. */
|
|
316
|
+
readonly publicEnvelope?: Cover;
|
|
318
317
|
/** Byte length of the inner v1 bundle (drives framing). */
|
|
319
318
|
readonly innerBytes: number;
|
|
320
319
|
/** SHA-256 (lowercase hex) of the inner v1 bundle bytes — pre-decrypt integrity. */
|
|
@@ -338,7 +337,7 @@ declare function decodeMultiBundle(bytes: Uint8Array): {
|
|
|
338
337
|
};
|
|
339
338
|
/** Per-compartment input to {@link writeMultiVaultBundle}. */
|
|
340
339
|
interface MultiVaultCompartmentInput {
|
|
341
|
-
readonly vault: Vault
|
|
340
|
+
readonly vault: Vault;
|
|
342
341
|
/** Owner-curated classification surfaced in the manifest (e.g. 'shard', 'pool'). */
|
|
343
342
|
readonly roleTag?: string;
|
|
344
343
|
/** ISO timestamp for the manifest; defaults to now. */
|
|
@@ -352,8 +351,8 @@ interface MultiVaultCompartmentInput {
|
|
|
352
351
|
/** `true` → surface the inner bundle's public envelope into the manifest. */
|
|
353
352
|
readonly publicEnvelope?: boolean;
|
|
354
353
|
};
|
|
355
|
-
/** Options forwarded to `
|
|
356
|
-
readonly bundleOptions?:
|
|
354
|
+
/** Options forwarded to `writePod` for this compartment's inner bundle. */
|
|
355
|
+
readonly bundleOptions?: WritePodOptions;
|
|
357
356
|
}
|
|
358
357
|
/** Write N vaults into one `NDBM` multi-compartment bundle. */
|
|
359
358
|
declare function writeMultiVaultBundle(compartments: readonly MultiVaultCompartmentInput[], opts?: {
|
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import { Vault, SealingKeyProvider,
|
|
2
|
-
export { CustodyApi, DeedMarker, GrantCustodianOptions, LiberateOptions, LiberateResult, createDeedOwner, isDeedVault, liberateVault, loadDeedMarker } from '@noy-db/hub';
|
|
3
|
-
import { a as VaultTemplate, S as StateManagementVault, V as VaultGroup, b as SkippedVault, M as MergeCompartmentOptions, c as MergeReport, d as SurfaceDirection, e as SurfaceConflictPolicy, f as SurfaceRow, g as VaultGroupOptions } from './vault-group-
|
|
4
|
-
export { C as CapturedBlueprint, h as CrossVaultAggregation, i as CrossVaultDerivationContext, j as CrossVaultDerivationSpec, k as CrossVaultGroupedAggregation, G as CrossVaultGroupedRow, l as CrossVaultLiveAggregation, m as CrossVaultLiveQuery, D as DecryptedMergeOptions, n as DeploymentEvent, F as FanoutQueryOptions, o as FanoutResult, p as FederatedRetrieveHit, q as FederatedRetrieveOptions, r as FederatedRetrieveResult, s as FederationMeta, t as FieldAuthorityInputs, u as FieldAuthorityPolicy, v as FieldAuthorityPolicyMissingError, w as FieldAuthorityRule, x as FieldLevelDeferredError, y as GroupMeta, I as InsightAutoPushConfig, L as LiveQueryOptions, z as MergeConflict, A as MergeStrategy, B as MigrationStatusRow, R as RefreshInsightsResult, E as SchemaManifestRow, H as SchemaRolloutResult, J as ShardedCollection, K as ShardedGroupedQuery, N as ShardedQuery, O as ShardingConfig, P as SurfaceStatus, Q as VaultRegistryRow, T as mergeCompartment, U as mergeDecryptedRecords, W as resolveFieldAuthority, X as resolveRecordByFieldAuthority } from './vault-group-
|
|
1
|
+
import { Vault, SealingKeyProvider, Noydb } from '@noy-db/hub/cargo';
|
|
2
|
+
export { CrossShardJoinError, CustodyApi, DataResidencyError, DeedMarker, GrantCustodianOptions, LiberateOptions, LiberateResult, ReservedVaultNameError, ShardProvisioningError, UnknownShardError, VaultTemplateNotFoundError, createDeedOwner, isDeedVault, liberateVault, loadDeedMarker } from '@noy-db/hub/cargo';
|
|
3
|
+
import { a as VaultTemplate, S as StateManagementVault, V as VaultGroup, b as SkippedVault, M as MergeCompartmentOptions, c as MergeReport, d as SurfaceDirection, e as SurfaceConflictPolicy, f as SurfaceRow, g as VaultGroupOptions } from './vault-group-D0EC-D5c.js';
|
|
4
|
+
export { C as CapturedBlueprint, h as CrossVaultAggregation, i as CrossVaultDerivationContext, j as CrossVaultDerivationSpec, k as CrossVaultGroupedAggregation, G as CrossVaultGroupedRow, l as CrossVaultLiveAggregation, m as CrossVaultLiveQuery, D as DecryptedMergeOptions, n as DeploymentEvent, F as FanoutQueryOptions, o as FanoutResult, p as FederatedRetrieveHit, q as FederatedRetrieveOptions, r as FederatedRetrieveResult, s as FederationMeta, t as FieldAuthorityInputs, u as FieldAuthorityPolicy, v as FieldAuthorityPolicyMissingError, w as FieldAuthorityRule, x as FieldLevelDeferredError, y as GroupMeta, I as InsightAutoPushConfig, L as LiveQueryOptions, z as MergeConflict, A as MergeStrategy, B as MigrationStatusRow, R as RefreshInsightsResult, E as SchemaManifestRow, H as SchemaRolloutResult, J as ShardedCollection, K as ShardedGroupedQuery, N as ShardedQuery, O as ShardingConfig, P as SurfaceStatus, Q as VaultRegistryRow, T as mergeCompartment, U as mergeDecryptedRecords, W as resolveFieldAuthority, X as resolveRecordByFieldAuthority } from './vault-group-D0EC-D5c.js';
|
|
5
5
|
import { AsXlsxSheetOptions } from '@noy-db/as-xlsx';
|
|
6
6
|
export { MultiVaultDenormColumn, MultiVaultXlsxEntry, MultiVaultXlsxOptions } from '@noy-db/as-xlsx';
|
|
7
|
-
import { ExtractionPreview
|
|
8
|
-
import { Vault as Vault$1 } from '@noy-db/hub/kernel';
|
|
9
|
-
export { CrossShardJoinError, DataResidencyError, ReservedVaultNameError, ShardProvisioningError, UnknownShardError, VaultTemplateNotFoundError } from '@noy-db/hub/kernel';
|
|
7
|
+
import { ExtractionPreview } from '@noy-db/hub/bundle';
|
|
10
8
|
import { InspectableContainer } from '@noy-db/in-devtools';
|
|
9
|
+
import { Cover, WritePodOptions } from '@noy-db/hub/pod';
|
|
11
10
|
|
|
12
11
|
/**
|
|
13
12
|
* @klum-db/lobby interchange — cross-vault FK-closure extraction.
|
|
@@ -284,7 +283,7 @@ declare function meterGroup<T>(group: VaultGroup<T>, opts?: {
|
|
|
284
283
|
* that embeds N standard single-vault `.noydb` bundles plus an
|
|
285
284
|
* unencrypted, owner-curated **manifest**. The v1 single-vault format
|
|
286
285
|
* is untouched; each compartment is a complete v1 bundle, produced by
|
|
287
|
-
* `
|
|
286
|
+
* `writePod` and read by `readNoydbBundle`.
|
|
288
287
|
*
|
|
289
288
|
* Layout: magic 'NDBM'(4) · version(1) · reserved(1) · manifestLen(4 BE)
|
|
290
289
|
* · manifest JSON · concat(inner v1 bundles, in manifest order).
|
|
@@ -313,8 +312,8 @@ interface CompartmentManifest {
|
|
|
313
312
|
readonly name: string;
|
|
314
313
|
readonly count: number;
|
|
315
314
|
}[];
|
|
316
|
-
/** Inner bundle's owner-curated public envelope
|
|
317
|
-
readonly publicEnvelope?:
|
|
315
|
+
/** Inner bundle's owner-curated cover (né public envelope — manifest key is this repo's wire). Opt-in. */
|
|
316
|
+
readonly publicEnvelope?: Cover;
|
|
318
317
|
/** Byte length of the inner v1 bundle (drives framing). */
|
|
319
318
|
readonly innerBytes: number;
|
|
320
319
|
/** SHA-256 (lowercase hex) of the inner v1 bundle bytes — pre-decrypt integrity. */
|
|
@@ -338,7 +337,7 @@ declare function decodeMultiBundle(bytes: Uint8Array): {
|
|
|
338
337
|
};
|
|
339
338
|
/** Per-compartment input to {@link writeMultiVaultBundle}. */
|
|
340
339
|
interface MultiVaultCompartmentInput {
|
|
341
|
-
readonly vault: Vault
|
|
340
|
+
readonly vault: Vault;
|
|
342
341
|
/** Owner-curated classification surfaced in the manifest (e.g. 'shard', 'pool'). */
|
|
343
342
|
readonly roleTag?: string;
|
|
344
343
|
/** ISO timestamp for the manifest; defaults to now. */
|
|
@@ -352,8 +351,8 @@ interface MultiVaultCompartmentInput {
|
|
|
352
351
|
/** `true` → surface the inner bundle's public envelope into the manifest. */
|
|
353
352
|
readonly publicEnvelope?: boolean;
|
|
354
353
|
};
|
|
355
|
-
/** Options forwarded to `
|
|
356
|
-
readonly bundleOptions?:
|
|
354
|
+
/** Options forwarded to `writePod` for this compartment's inner bundle. */
|
|
355
|
+
readonly bundleOptions?: WritePodOptions;
|
|
357
356
|
}
|
|
358
357
|
/** Write N vaults into one `NDBM` multi-compartment bundle. */
|
|
359
358
|
declare function writeMultiVaultBundle(compartments: readonly MultiVaultCompartmentInput[], opts?: {
|
package/dist/index.js
CHANGED
|
@@ -25,15 +25,13 @@ var init_uint32 = __esm({
|
|
|
25
25
|
});
|
|
26
26
|
|
|
27
27
|
// src/bundle/multi-bundle.ts
|
|
28
|
-
import { sha256Hex, generateULID } from "@noy-db/hub/
|
|
28
|
+
import { sha256Hex, generateULID } from "@noy-db/hub/cargo";
|
|
29
29
|
import {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
hasNoydbBundleMagic
|
|
36
|
-
} from "@noy-db/hub";
|
|
30
|
+
writePod,
|
|
31
|
+
readPodHeader,
|
|
32
|
+
readPodCover,
|
|
33
|
+
NOYDB_BUNDLE_MAGIC
|
|
34
|
+
} from "@noy-db/hub/pod";
|
|
37
35
|
function encodeMultiBundle(manifest, inner) {
|
|
38
36
|
validateManifest(manifest);
|
|
39
37
|
if (manifest.compartments.length !== inner.length) {
|
|
@@ -59,6 +57,11 @@ function encodeMultiBundle(manifest, inner) {
|
|
|
59
57
|
}
|
|
60
58
|
return out;
|
|
61
59
|
}
|
|
60
|
+
function hasPodMagic(bytes) {
|
|
61
|
+
if (bytes.length < NOYDB_BUNDLE_MAGIC.length) return false;
|
|
62
|
+
for (let i = 0; i < NOYDB_BUNDLE_MAGIC.length; i++) if (bytes[i] !== NOYDB_BUNDLE_MAGIC[i]) return false;
|
|
63
|
+
return true;
|
|
64
|
+
}
|
|
62
65
|
function hasMultiMagic(bytes) {
|
|
63
66
|
if (bytes.length < NOYDB_MULTI_BUNDLE_MAGIC.length) return false;
|
|
64
67
|
for (let i = 0; i < NOYDB_MULTI_BUNDLE_MAGIC.length; i++) if (bytes[i] !== NOYDB_MULTI_BUNDLE_MAGIC[i]) return false;
|
|
@@ -116,8 +119,8 @@ async function writeMultiVaultBundle(compartments, opts = {}) {
|
|
|
116
119
|
const inner = [];
|
|
117
120
|
const entries = [];
|
|
118
121
|
for (const c of compartments) {
|
|
119
|
-
const innerBytes = await
|
|
120
|
-
const header =
|
|
122
|
+
const innerBytes = await writePod(c.vault, c.bundleOptions ?? {});
|
|
123
|
+
const header = readPodHeader(innerBytes);
|
|
121
124
|
const entry = {
|
|
122
125
|
handle: header.handle,
|
|
123
126
|
exportedAt: c.exportedAt ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
@@ -135,7 +138,7 @@ async function writeMultiVaultBundle(compartments, opts = {}) {
|
|
|
135
138
|
);
|
|
136
139
|
}
|
|
137
140
|
if (c.disclose?.publicEnvelope === true) {
|
|
138
|
-
const env =
|
|
141
|
+
const env = readPodCover(innerBytes);
|
|
139
142
|
if (env !== void 0) entry.publicEnvelope = env;
|
|
140
143
|
}
|
|
141
144
|
const fence = await c.vault.schemaFenceState();
|
|
@@ -152,9 +155,9 @@ async function writeMultiVaultBundle(compartments, opts = {}) {
|
|
|
152
155
|
}
|
|
153
156
|
async function readNoydbBundleManifest(bytes) {
|
|
154
157
|
if (hasMultiMagic(bytes)) return [...decodeMultiBundle(bytes).manifest.compartments];
|
|
155
|
-
if (
|
|
156
|
-
const header =
|
|
157
|
-
const env =
|
|
158
|
+
if (hasPodMagic(bytes)) {
|
|
159
|
+
const header = readPodHeader(bytes);
|
|
160
|
+
const env = readPodCover(bytes);
|
|
158
161
|
const entry = {
|
|
159
162
|
handle: header.handle,
|
|
160
163
|
innerBytes: bytes.length,
|
|
@@ -169,8 +172,8 @@ function readMultiVaultBundleCompartment(bytes, selector) {
|
|
|
169
172
|
if (typeof selector === "number" && !Number.isInteger(selector)) {
|
|
170
173
|
throw new Error(`readMultiVaultBundleCompartment: numeric selector must be an integer, got ${selector}.`);
|
|
171
174
|
}
|
|
172
|
-
if (
|
|
173
|
-
const header =
|
|
175
|
+
if (hasPodMagic(bytes) && !hasMultiMagic(bytes)) {
|
|
176
|
+
const header = readPodHeader(bytes);
|
|
174
177
|
if (selector === 0 || selector === header.handle) return bytes;
|
|
175
178
|
throw new Error(`readMultiVaultBundleCompartment: single v1 bundle has only compartment "${header.handle}".`);
|
|
176
179
|
}
|
|
@@ -201,10 +204,10 @@ __export(extract_cross_vault_exports, {
|
|
|
201
204
|
import {
|
|
202
205
|
walkClosure,
|
|
203
206
|
extractPartition,
|
|
204
|
-
readNoydbBundleHeader as readNoydbBundleHeader2,
|
|
205
207
|
describeExtraction
|
|
206
208
|
} from "@noy-db/hub/bundle";
|
|
207
|
-
import {
|
|
209
|
+
import { readPodHeader as readPodHeader2 } from "@noy-db/hub/pod";
|
|
210
|
+
import { sha256Hex as sha256Hex2, generateULID as generateULID2 } from "@noy-db/hub/cargo";
|
|
208
211
|
function asIdArray(v) {
|
|
209
212
|
if (v === null || v === void 0) return [];
|
|
210
213
|
if (Array.isArray(v)) return v.filter((x) => typeof x === "string" || typeof x === "number").map(String);
|
|
@@ -321,7 +324,7 @@ async function extractCrossVaultPartition(openVault, opts) {
|
|
|
321
324
|
carryLedger: opts.carryLedger ?? false,
|
|
322
325
|
...opts.compression !== void 0 ? { compression: opts.compression } : {}
|
|
323
326
|
});
|
|
324
|
-
const header =
|
|
327
|
+
const header = readPodHeader2(bundleBytes);
|
|
325
328
|
const meta = opts.compartmentMeta?.[vaultName];
|
|
326
329
|
const entry = {
|
|
327
330
|
handle: header.handle,
|
|
@@ -429,7 +432,7 @@ var init_field_authority = __esm({
|
|
|
429
432
|
});
|
|
430
433
|
|
|
431
434
|
// src/interchange/merge-compartment.ts
|
|
432
|
-
import { diffVault } from "@noy-db/hub";
|
|
435
|
+
import { diffVault } from "@noy-db/hub/cargo";
|
|
433
436
|
import { decryptExtractedPartition } from "@noy-db/hub/bundle";
|
|
434
437
|
function strategyFor(opts, collection) {
|
|
435
438
|
if (typeof opts === "string") return opts;
|
|
@@ -638,7 +641,7 @@ __export(graduate_exports, {
|
|
|
638
641
|
UnitGraduationError: () => UnitGraduationError,
|
|
639
642
|
graduate: () => graduate
|
|
640
643
|
});
|
|
641
|
-
import { createDeedOwner } from "@noy-db/hub";
|
|
644
|
+
import { createDeedOwner } from "@noy-db/hub/cargo";
|
|
642
645
|
async function graduate(noydb, docked, opts) {
|
|
643
646
|
const vault = await noydb.openVault(opts.vaultName);
|
|
644
647
|
opts.template.configure(vault);
|
|
@@ -724,7 +727,7 @@ __export(surface_exports, {
|
|
|
724
727
|
markSynced: () => markSynced,
|
|
725
728
|
proposeSurface: () => proposeSurface
|
|
726
729
|
});
|
|
727
|
-
import { generateULID as generateULID3 } from "@noy-db/hub/
|
|
730
|
+
import { generateULID as generateULID3 } from "@noy-db/hub/cargo";
|
|
728
731
|
import { extractPartition as extractPartition2 } from "@noy-db/hub/bundle";
|
|
729
732
|
async function proposeSurface(smv, def, proposedBy, now) {
|
|
730
733
|
const row = {
|
|
@@ -846,7 +849,7 @@ var init_surface = __esm({
|
|
|
846
849
|
});
|
|
847
850
|
|
|
848
851
|
// src/federation/schema-manifest.ts
|
|
849
|
-
import { sha256Hex as sha256Hex3 } from "@noy-db/hub/
|
|
852
|
+
import { sha256Hex as sha256Hex3 } from "@noy-db/hub/cargo";
|
|
850
853
|
function captureBlueprint(configure) {
|
|
851
854
|
const recorded = [];
|
|
852
855
|
const collectionStub = new Proxy(
|
|
@@ -906,7 +909,7 @@ var init_schema_manifest = __esm({
|
|
|
906
909
|
});
|
|
907
910
|
|
|
908
911
|
// src/federation/constants.ts
|
|
909
|
-
import { STATE_VAULT_NAME } from "@noy-db/hub";
|
|
912
|
+
import { STATE_VAULT_NAME } from "@noy-db/hub/cargo";
|
|
910
913
|
var init_constants = __esm({
|
|
911
914
|
"src/federation/constants.ts"() {
|
|
912
915
|
"use strict";
|
|
@@ -919,7 +922,7 @@ __export(state_vault_exports, {
|
|
|
919
922
|
STATE_VAULT_NAME: () => STATE_VAULT_NAME,
|
|
920
923
|
StateManagementVault: () => StateManagementVault
|
|
921
924
|
});
|
|
922
|
-
import { generateULID as generateULID4 } from "@noy-db/hub/
|
|
925
|
+
import { generateULID as generateULID4 } from "@noy-db/hub/cargo";
|
|
923
926
|
var REGISTRY, MANIFEST, EVENTS, MIGRATION_STATUS, SURFACES, StateManagementVault;
|
|
924
927
|
var init_state_vault = __esm({
|
|
925
928
|
"src/federation/state-vault.ts"() {
|
|
@@ -1056,7 +1059,7 @@ var init_state_vault = __esm({
|
|
|
1056
1059
|
});
|
|
1057
1060
|
|
|
1058
1061
|
// src/federation/classify-skip.ts
|
|
1059
|
-
import { NoAccessError } from "@noy-db/hub/
|
|
1062
|
+
import { NoAccessError } from "@noy-db/hub/cargo";
|
|
1060
1063
|
function classifyShardSkip(err) {
|
|
1061
1064
|
return err instanceof NoAccessError ? "no-grant" : "error";
|
|
1062
1065
|
}
|
|
@@ -1067,7 +1070,7 @@ var init_classify_skip = __esm({
|
|
|
1067
1070
|
});
|
|
1068
1071
|
|
|
1069
1072
|
// src/federation/cross-shard-join.ts
|
|
1070
|
-
import { readPath } from "@noy-db/hub/
|
|
1073
|
+
import { readPath } from "@noy-db/hub/cargo";
|
|
1071
1074
|
function coerceKey(value) {
|
|
1072
1075
|
if (value === null || value === void 0) return null;
|
|
1073
1076
|
if (typeof value === "string") return value;
|
|
@@ -1320,8 +1323,8 @@ var init_partial_reduce = __esm({
|
|
|
1320
1323
|
});
|
|
1321
1324
|
|
|
1322
1325
|
// src/federation/aggregate-across.ts
|
|
1323
|
-
import { reduceRecords } from "@noy-db/hub/
|
|
1324
|
-
import { groupAndReduce } from "@noy-db/hub/
|
|
1326
|
+
import { reduceRecords } from "@noy-db/hub/cargo";
|
|
1327
|
+
import { groupAndReduce } from "@noy-db/hub/cargo";
|
|
1325
1328
|
var CrossVaultAggregation, CrossVaultGroupedAggregation;
|
|
1326
1329
|
var init_aggregate_across = __esm({
|
|
1327
1330
|
"src/federation/aggregate-across.ts"() {
|
|
@@ -1431,7 +1434,7 @@ var init_aggregate_across = __esm({
|
|
|
1431
1434
|
});
|
|
1432
1435
|
|
|
1433
1436
|
// src/federation/retrieve-across.ts
|
|
1434
|
-
import { fuseRetrieval } from "@noy-db/hub/
|
|
1437
|
+
import { fuseRetrieval } from "@noy-db/hub/cargo";
|
|
1435
1438
|
async function retrieveAcross(group, collectionName, query, opts = {}) {
|
|
1436
1439
|
const { eligible, skipped } = await group.resolveEligible({
|
|
1437
1440
|
...opts.minVersion !== void 0 ? { minVersion: opts.minVersion } : {},
|
|
@@ -1505,7 +1508,7 @@ __export(vault_group_exports, {
|
|
|
1505
1508
|
ShardedQuery: () => ShardedQuery,
|
|
1506
1509
|
VaultGroup: () => VaultGroup
|
|
1507
1510
|
});
|
|
1508
|
-
import { CrossShardJoinError, DataResidencyError, ReservedVaultNameError, ShardProvisioningError, UnknownShardError, ValidationError } from "@noy-db/hub/
|
|
1511
|
+
import { CrossShardJoinError, DataResidencyError, ReservedVaultNameError, ShardProvisioningError, UnknownShardError, ValidationError } from "@noy-db/hub/cargo";
|
|
1509
1512
|
function autoPushConfig(spec) {
|
|
1510
1513
|
if (!spec.autoPush) return null;
|
|
1511
1514
|
return spec.autoPush === true ? {} : spec.autoPush;
|
|
@@ -2222,8 +2225,7 @@ var init_vault_group = __esm({
|
|
|
2222
2225
|
});
|
|
2223
2226
|
|
|
2224
2227
|
// src/index.ts
|
|
2225
|
-
import { ValidationError as ValidationError2, ReservedVaultNameError as ReservedVaultNameError2, VaultTemplateNotFoundError } from "@noy-db/hub/
|
|
2226
|
-
import { STATE_VAULT_NAME as STATE_VAULT_NAME2 } from "@noy-db/hub";
|
|
2228
|
+
import { ValidationError as ValidationError2, ReservedVaultNameError as ReservedVaultNameError2, VaultTemplateNotFoundError, STATE_VAULT_NAME as STATE_VAULT_NAME2 } from "@noy-db/hub/cargo";
|
|
2227
2229
|
|
|
2228
2230
|
// src/dock/docked-unit.ts
|
|
2229
2231
|
var DockedUnit = class {
|
|
@@ -2315,7 +2317,7 @@ import {
|
|
|
2315
2317
|
VaultTemplateNotFoundError as VaultTemplateNotFoundError2,
|
|
2316
2318
|
ReservedVaultNameError as ReservedVaultNameError3,
|
|
2317
2319
|
DataResidencyError as DataResidencyError2
|
|
2318
|
-
} from "@noy-db/hub/
|
|
2320
|
+
} from "@noy-db/hub/cargo";
|
|
2319
2321
|
|
|
2320
2322
|
// src/interchange/migrate-then-merge.ts
|
|
2321
2323
|
init_merge_compartment();
|
|
@@ -2366,7 +2368,7 @@ async function migrateThenMerge(receiver, compartmentBytes, opts) {
|
|
|
2366
2368
|
|
|
2367
2369
|
// src/index.ts
|
|
2368
2370
|
init_field_authority();
|
|
2369
|
-
import { CustodyApi, liberateVault, createDeedOwner as createDeedOwner2, loadDeedMarker, isDeedVault } from "@noy-db/hub";
|
|
2371
|
+
import { CustodyApi, liberateVault, createDeedOwner as createDeedOwner2, loadDeedMarker, isDeedVault } from "@noy-db/hub/cargo";
|
|
2370
2372
|
|
|
2371
2373
|
// src/dock/unit-driver.ts
|
|
2372
2374
|
var InMemoryUnitDriver = class {
|