@noy-db/hub 0.7.0 → 0.8.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/CHANGELOG.md +105 -14
- package/LICENSE +202 -21
- package/NOTICE +1 -0
- package/README.md +27 -10
- package/codemods/0.8.0-pre.json +61 -0
- package/dist/api-GVYEKSJE.js +19 -0
- package/dist/as/index.js +11 -11
- package/dist/at/index.js +9 -9
- package/dist/attestation/index.js +20 -20
- package/dist/{backup-IJTB4S4M.js → backup-7TFRVFLH.js} +21 -15
- package/dist/backup-7TFRVFLH.js.map +1 -0
- package/dist/blobs/index.js +13 -13
- package/dist/broker/index.js +12 -12
- package/dist/by/index.js +2 -2
- package/dist/cargo/index.js +39 -36
- package/dist/{chunk-7O3Y4PPD.js → chunk-244VXYPG.js} +140 -16
- package/dist/chunk-244VXYPG.js.map +1 -0
- package/dist/{chunk-BUE2D7PX.js → chunk-32YV3TJT.js} +2 -2
- package/dist/{chunk-3RCJJBNR.js → chunk-3ELRMVJK.js} +12 -12
- package/dist/{chunk-6GMZ7HEE.js → chunk-3F7GLNAE.js} +6 -6
- package/dist/{chunk-2Y4IMKA6.js → chunk-3H5KLDZN.js} +4 -4
- package/dist/{chunk-VTFVLCUH.js → chunk-3JWHAR6E.js} +2 -2
- package/dist/{chunk-YMUFFJCO.js → chunk-3TDUWVWB.js} +5 -2
- package/dist/chunk-3TDUWVWB.js.map +1 -0
- package/dist/{chunk-JBDFMYKQ.js → chunk-4AF3TUMP.js} +2 -2
- package/dist/{chunk-ZORTV6NH.js → chunk-4I522ERM.js} +88 -4
- package/dist/chunk-4I522ERM.js.map +1 -0
- package/dist/{chunk-MUM7IANK.js → chunk-4MXI3ODD.js} +4 -4
- package/dist/chunk-4MXI3ODD.js.map +1 -0
- package/dist/{chunk-BLN54W3L.js → chunk-5FDLC6G7.js} +56 -3
- package/dist/chunk-5FDLC6G7.js.map +1 -0
- package/dist/chunk-5O7D6ZTW.js +53 -0
- package/dist/chunk-5O7D6ZTW.js.map +1 -0
- package/dist/{chunk-J6FXAEUG.js → chunk-6B3VNR4P.js} +12 -12
- package/dist/{chunk-TUFM4UZP.js → chunk-6K7DPM7D.js} +2 -2
- package/dist/{chunk-K6LHRFBL.js → chunk-6LMQ5R26.js} +7 -7
- package/dist/{chunk-SPXXX5E4.js → chunk-6LNL42F5.js} +94 -32
- package/dist/chunk-6LNL42F5.js.map +1 -0
- package/dist/{chunk-XLMEZIAJ.js → chunk-6OWXYZK2.js} +2 -2
- package/dist/{chunk-BOWNCWZT.js → chunk-6QSQQLSE.js} +3 -3
- package/dist/chunk-7JE7BDYJ.js +1558 -0
- package/dist/chunk-7JE7BDYJ.js.map +1 -0
- package/dist/{chunk-KG7TZKZG.js → chunk-7VCXZDA4.js} +5 -5
- package/dist/chunk-7VCXZDA4.js.map +1 -0
- package/dist/{chunk-NQKIUNW5.js → chunk-A6IJU4TK.js} +2 -2
- package/dist/{chunk-BM5TWITZ.js → chunk-ANWPSTZU.js} +38 -9
- package/dist/chunk-ANWPSTZU.js.map +1 -0
- package/dist/{chunk-QIZPZMUI.js → chunk-AOWGXU6D.js} +2 -2
- package/dist/{chunk-CUZLNGD5.js → chunk-B2YY6WDD.js} +1 -1
- package/dist/chunk-B2YY6WDD.js.map +1 -0
- package/dist/{chunk-SFAWCTEM.js → chunk-B57AFBY2.js} +2 -2
- package/dist/{chunk-GPEQUXHL.js → chunk-B6SJIBQK.js} +4 -4
- package/dist/chunk-BJ2IXQ5Q.js +100 -0
- package/dist/chunk-BJ2IXQ5Q.js.map +1 -0
- package/dist/{chunk-Q2PU57HC.js → chunk-BK2HHQGN.js} +2 -2
- package/dist/chunk-BKT776R5.js +1 -0
- package/dist/{chunk-KUX3OB6D.js → chunk-BP6DARYA.js} +33 -5
- package/dist/chunk-BP6DARYA.js.map +1 -0
- package/dist/{chunk-FXBIP2WD.js → chunk-BUDAGWL5.js} +6 -6
- package/dist/chunk-CF5UU4S7.js +757 -0
- package/dist/chunk-CF5UU4S7.js.map +1 -0
- package/dist/{chunk-BOET4NA4.js → chunk-CKNGS5MH.js} +3 -3
- package/dist/chunk-CY2CYVWZ.js +41 -0
- package/dist/chunk-CY2CYVWZ.js.map +1 -0
- package/dist/{chunk-2577DKXB.js → chunk-DC5QVPV7.js} +2 -2
- package/dist/chunk-DC5QVPV7.js.map +1 -0
- package/dist/{chunk-YSRUYAVU.js → chunk-DE4DH2RZ.js} +2 -2
- package/dist/{chunk-6I2RQCET.js → chunk-DF73H4UN.js} +4 -4
- package/dist/{chunk-4GVM6QZA.js → chunk-ENAG3IY7.js} +2 -2
- package/dist/chunk-ENAG3IY7.js.map +1 -0
- package/dist/{chunk-K7NTTA6P.js → chunk-EOVMT6TB.js} +2 -2
- package/dist/chunk-F24ZZTHQ.js +193 -0
- package/dist/chunk-F24ZZTHQ.js.map +1 -0
- package/dist/chunk-F2TDU7MQ.js +456 -0
- package/dist/chunk-F2TDU7MQ.js.map +1 -0
- package/dist/chunk-F6NCB7KT.js +13 -0
- package/dist/chunk-F6NCB7KT.js.map +1 -0
- package/dist/{chunk-SPYWXKJN.js → chunk-F7XGHL5O.js} +3 -3
- package/dist/chunk-F7XGHL5O.js.map +1 -0
- package/dist/{chunk-XTXOCYOJ.js → chunk-FCKWQE2H.js} +5 -5
- package/dist/{chunk-U4FOQDY4.js → chunk-FH2L2E34.js} +4 -4
- package/dist/chunk-FH2L2E34.js.map +1 -0
- package/dist/{chunk-4OZNXTO4.js → chunk-FN5EBVTQ.js} +2 -2
- package/dist/chunk-FQ54DWUQ.js +270 -0
- package/dist/chunk-FQ54DWUQ.js.map +1 -0
- package/dist/{chunk-NKHRDYOR.js → chunk-FQ5VRHIB.js} +4 -4
- package/dist/{chunk-FAHMLERK.js → chunk-FW22ZCXT.js} +2 -2
- package/dist/chunk-FXQBGFOX.js +524 -0
- package/dist/chunk-FXQBGFOX.js.map +1 -0
- package/dist/{chunk-AO42KJO6.js → chunk-GF5BZ7D4.js} +45 -9
- package/dist/chunk-GF5BZ7D4.js.map +1 -0
- package/dist/{chunk-TRGTKX5E.js → chunk-GHLTDZRS.js} +5 -3
- package/dist/{chunk-TRGTKX5E.js.map → chunk-GHLTDZRS.js.map} +1 -1
- package/dist/{chunk-5WDXHNSW.js → chunk-HBPPGWUM.js} +5 -5
- package/dist/chunk-HBPPGWUM.js.map +1 -0
- package/dist/{chunk-KTFRCC5C.js → chunk-HBRLNOHL.js} +82 -8
- package/dist/chunk-HBRLNOHL.js.map +1 -0
- package/dist/chunk-HLEK5VAN.js +275 -0
- package/dist/chunk-HLEK5VAN.js.map +1 -0
- package/dist/{chunk-RMS3NEA3.js → chunk-HT2AHGQI.js} +2 -2
- package/dist/{chunk-CHJBLCOG.js → chunk-HVSCEIYL.js} +7 -7
- package/dist/{chunk-UXWB3FPF.js → chunk-I3JDRCMW.js} +150 -22
- package/dist/chunk-I3JDRCMW.js.map +1 -0
- package/dist/{chunk-GY4WYNNG.js → chunk-ID6Z6E66.js} +2 -2
- package/dist/{chunk-EYBQEIUY.js → chunk-IEX7NK2K.js} +3 -3
- package/dist/{chunk-KUJDV5QH.js → chunk-ISZQJBML.js} +5 -5
- package/dist/{chunk-LWBCUYZW.js → chunk-IT22PWKV.js} +2 -2
- package/dist/{chunk-EQEYOJBM.js → chunk-IUWCVHQ7.js} +3 -3
- package/dist/chunk-IUWCVHQ7.js.map +1 -0
- package/dist/{chunk-7V4TP3AF.js → chunk-J6UOHJY5.js} +4 -4
- package/dist/{chunk-JMGDHKQF.js → chunk-JCN44NCY.js} +2 -2
- package/dist/{chunk-CARABLSQ.js → chunk-K6W7BVZ6.js} +3 -3
- package/dist/{chunk-77K4PG6P.js → chunk-KJFW62P4.js} +29 -11
- package/dist/chunk-KJFW62P4.js.map +1 -0
- package/dist/{chunk-453F654R.js → chunk-L7DOS3TE.js} +2 -2
- package/dist/chunk-LGNDFRYC.js +23 -0
- package/dist/chunk-LGNDFRYC.js.map +1 -0
- package/dist/{chunk-WEQEYLCS.js → chunk-LGRLME4M.js} +7 -7
- package/dist/{chunk-RMF67KCG.js → chunk-LQ4ZHOKP.js} +2 -2
- package/dist/{chunk-ZVO4QVPD.js → chunk-M522UYZ2.js} +5 -5
- package/dist/{chunk-G56KBWFY.js → chunk-M7NI3IWE.js} +45 -12
- package/dist/chunk-M7NI3IWE.js.map +1 -0
- package/dist/chunk-MDWKM2XC.js +293 -0
- package/dist/chunk-MDWKM2XC.js.map +1 -0
- package/dist/chunk-MKXXMNJH.js +204 -0
- package/dist/chunk-MKXXMNJH.js.map +1 -0
- package/dist/{chunk-SKGMN35F.js → chunk-MLPHLJIQ.js} +3 -3
- package/dist/chunk-MLPHLJIQ.js.map +1 -0
- package/dist/{chunk-2N4GY74U.js → chunk-MTL7MXGR.js} +6 -6
- package/dist/{chunk-TFR7DSOV.js → chunk-MVZ2TPVP.js} +2 -2
- package/dist/{chunk-CPWQB3N5.js → chunk-N5DNADLQ.js} +7 -7
- package/dist/{chunk-ELNXJMGB.js → chunk-NNARWO72.js} +6 -6
- package/dist/{chunk-PT43Y56J.js → chunk-NRT6QZQB.js} +102 -16
- package/dist/chunk-NRT6QZQB.js.map +1 -0
- package/dist/{chunk-QIBVIOXO.js → chunk-NWHBJQAL.js} +99 -8
- package/dist/chunk-NWHBJQAL.js.map +1 -0
- package/dist/chunk-NYMLINRP.js +28 -0
- package/dist/chunk-NYMLINRP.js.map +1 -0
- package/dist/{chunk-7MG7SJT7.js → chunk-ODVPTDPK.js} +1 -1
- package/dist/chunk-ODVPTDPK.js.map +1 -0
- package/dist/chunk-ORDURZBU.js +461 -0
- package/dist/chunk-ORDURZBU.js.map +1 -0
- package/dist/{chunk-6YXCPL4T.js → chunk-PDCG6PR5.js} +2 -2
- package/dist/{chunk-REDOOY2Q.js → chunk-PSIV7CJV.js} +2 -2
- package/dist/{chunk-NA2NIJZI.js → chunk-QBBUZ3I3.js} +126 -19
- package/dist/chunk-QBBUZ3I3.js.map +1 -0
- package/dist/{chunk-5VCRVKOZ.js → chunk-QOOUUR4A.js} +6 -4
- package/dist/{chunk-5VCRVKOZ.js.map → chunk-QOOUUR4A.js.map} +1 -1
- package/dist/{chunk-ANATMFIO.js → chunk-QWFHIOD2.js} +5 -5
- package/dist/{chunk-X2DLENDQ.js → chunk-QWGU66MP.js} +3 -3
- package/dist/chunk-RHVMZSUU.js +7 -0
- package/dist/chunk-RHVMZSUU.js.map +1 -0
- package/dist/{chunk-BSFNRLK2.js → chunk-S57HTZ6X.js} +5 -5
- package/dist/{chunk-SZJ3DLZA.js → chunk-SEE332EV.js} +2 -2
- package/dist/{chunk-YYP7WSEB.js → chunk-SI3V7D4G.js} +2 -2
- package/dist/{chunk-UGTBXF5U.js → chunk-SOIQ4MM4.js} +3 -3
- package/dist/chunk-SUZKW6UR.js +25 -0
- package/dist/chunk-SUZKW6UR.js.map +1 -0
- package/dist/{chunk-VXGSWL6L.js → chunk-SYVZW77S.js} +6 -6
- package/dist/{chunk-6GOE5PGN.js → chunk-T2LBQ5DV.js} +883 -227
- package/dist/chunk-T2LBQ5DV.js.map +1 -0
- package/dist/chunk-T52GX4SA.js +215 -0
- package/dist/chunk-T52GX4SA.js.map +1 -0
- package/dist/{chunk-MVMXZYXT.js → chunk-TKUOEU2F.js} +2 -2
- package/dist/chunk-TOPYQ6GA.js +31 -0
- package/dist/chunk-TOPYQ6GA.js.map +1 -0
- package/dist/{chunk-SMH6SRX7.js → chunk-TROR3ALR.js} +2 -2
- package/dist/{chunk-2C3AQB46.js → chunk-UD5EVGZ7.js} +42 -389
- package/dist/chunk-UD5EVGZ7.js.map +1 -0
- package/dist/{chunk-KJIMGIWO.js → chunk-UPD5NWI5.js} +65 -17
- package/dist/chunk-UPD5NWI5.js.map +1 -0
- package/dist/{chunk-SL3JAAKN.js → chunk-UYB234ZR.js} +30 -2
- package/dist/chunk-UYB234ZR.js.map +1 -0
- package/dist/chunk-VHM7HCKB.js +220 -0
- package/dist/chunk-VHM7HCKB.js.map +1 -0
- package/dist/{chunk-DGOZ4UZD.js → chunk-VNNRUGMM.js} +2 -2
- package/dist/{chunk-HDOU6I2Y.js → chunk-VNPEWFPD.js} +4 -4
- package/dist/{chunk-L7CIOOBW.js → chunk-WNJ4AVGE.js} +2 -2
- package/dist/{chunk-FMZY5Q6L.js → chunk-WX5ADGTZ.js} +3 -3
- package/dist/{chunk-VXANTWBJ.js → chunk-WY2XXTET.js} +92 -6
- package/dist/{chunk-VXANTWBJ.js.map → chunk-WY2XXTET.js.map} +1 -1
- package/dist/{chunk-6X6SEMEE.js → chunk-X25NWUZB.js} +33 -8
- package/dist/chunk-X25NWUZB.js.map +1 -0
- package/dist/{chunk-Q7HZX3IF.js → chunk-X4773RBR.js} +2 -2
- package/dist/chunk-XBKH4FOC.js +195 -0
- package/dist/chunk-XBKH4FOC.js.map +1 -0
- package/dist/{chunk-ANSIZYEG.js → chunk-YNIUIERI.js} +3 -3
- package/dist/chunk-YSK2CU2Q.js +936 -0
- package/dist/chunk-YSK2CU2Q.js.map +1 -0
- package/dist/{chunk-UXVWEX5L.js → chunk-Z5HTYMMQ.js} +6 -2
- package/dist/chunk-Z5HTYMMQ.js.map +1 -0
- package/dist/{chunk-RRNRNANG.js → chunk-ZE4CHIED.js} +66 -75
- package/dist/chunk-ZE4CHIED.js.map +1 -0
- package/dist/chunk-ZSX4S5XB.js +1289 -0
- package/dist/chunk-ZSX4S5XB.js.map +1 -0
- package/dist/{chunk-BZ3534YM.js → chunk-ZUVBC32X.js} +2 -2
- package/dist/{chunk-L742JPKZ.js → chunk-ZXABPVM6.js} +6 -6
- package/dist/classified/index.js +5 -5
- package/dist/{classified-marker-LI2SF2E4.js → classified-marker-W3USLL5M.js} +3 -3
- package/dist/collection-facade-QU6IJBN3.js +48 -0
- package/dist/{computed-VPOKQK4N.js → computed-TPFBX7U4.js} +3 -3
- package/dist/consent/index.js +9 -9
- package/dist/cover/index.js +10 -10
- package/dist/coverage/index.js +306 -0
- package/dist/coverage/index.js.map +1 -0
- package/dist/custody/index.js +12 -12
- package/dist/{dead-filter-TSWZQRR5.js → dead-filter-U2UYKSZL.js} +2 -2
- package/dist/debug/index.js +1 -1
- package/dist/{delegation-OVIFFPG4.js → delegation-S3AEPW2T.js} +11 -11
- package/dist/derivations/index.js +25 -22
- package/dist/derive-OX7F6TGG.js +21 -0
- package/dist/directory/index.js +10 -10
- package/dist/{dispatch-WC6X2M6C.js → dispatch-3CQDJV5Q.js} +5 -5
- package/dist/{dispatch-S73TK3IY.js → dispatch-RH4LHKBH.js} +21 -21
- package/dist/{enclave-KJOTOH7X.js → enclave-27SMF6GF.js} +15 -9
- package/dist/executor-B6SRO2QS.js +36 -0
- package/dist/executor-BI5CHWRY.js +8 -0
- package/dist/executor-RBKM5W5K.js +8 -0
- package/dist/export-accessible-VMA3YM5V.js +22 -0
- package/dist/extract-partition-NF7PXGPP.js +37 -0
- package/dist/{fanout-sidecar-WUFXNYP4.js → fanout-sidecar-OT6RYLOL.js} +9 -9
- package/dist/find-LZMP26KF.js +10 -0
- package/dist/forget/index.js +9 -9
- package/dist/guards/index.js +4 -4
- package/dist/history/index.js +13 -13
- package/dist/i18n/index.js +14 -14
- package/dist/index.d.ts +29 -6
- package/dist/index.js +999 -191
- package/dist/index.js.map +1 -1
- package/dist/indexing/index.js +13 -5
- package/dist/indexing/index.js.map +1 -1
- package/dist/introspection/index.js +11 -11
- package/dist/issue-IHARXWW5.js +18 -0
- package/dist/ivf-flat-UZ6DQDLS.js +314 -0
- package/dist/ivf-flat-UZ6DQDLS.js.map +1 -0
- package/dist/{json-schema-V3M5MUCM.js → json-schema-3SHX72CC.js} +2 -1
- package/dist/json-schema-3SHX72CC.js.map +1 -0
- package/dist/kernel/collection-config.d.ts +4 -20
- package/dist/kernel/collection.d.ts +29 -8
- package/dist/kernel/enclave/crypto.d.ts +16 -0
- package/dist/kernel/enclave/index.d.ts +1 -1
- package/dist/kernel/enclave/record-keys/record-codec.d.ts +25 -0
- package/dist/kernel/errors.d.ts +227 -36
- package/dist/kernel/generation-map.d.ts +48 -0
- package/dist/kernel/memory-store.d.ts +35 -7
- package/dist/kernel/noydb.d.ts +6 -1
- package/dist/kernel/present-cache.d.ts +58 -0
- package/dist/kernel/query/all.d.ts +7 -0
- package/dist/kernel/query/builder.d.ts +601 -270
- package/dist/kernel/query/civil-date.d.ts +64 -0
- package/dist/kernel/query/cursor.d.ts +40 -0
- package/dist/kernel/query/distinct-key.d.ts +98 -0
- package/dist/kernel/query/hydration.d.ts +76 -0
- package/dist/kernel/query/index.d.ts +31 -15
- package/dist/kernel/query/internal/core.d.ts +30 -0
- package/dist/kernel/query/internal/hooks.d.ts +22 -0
- package/dist/kernel/query/internal/maintenance.d.ts +43 -0
- package/dist/kernel/query/live/incremental.d.ts +314 -0
- package/dist/kernel/query/live/index.d.ts +22 -0
- package/dist/kernel/query/live/install.d.ts +2 -0
- package/dist/kernel/query/{live.d.ts → live/live.d.ts} +39 -9
- package/dist/kernel/query/live/methods.d.ts +107 -0
- package/dist/kernel/query/predicate.d.ts +119 -1
- package/dist/kernel/query/reduce/date-trunc.d.ts +75 -0
- package/dist/kernel/query/reduce/index.d.ts +36 -0
- package/dist/kernel/query/reduce/install.d.ts +2 -0
- package/dist/kernel/query/reduce/methods.d.ts +259 -0
- package/dist/kernel/query/reduce/scan-methods.d.ts +121 -0
- package/dist/kernel/query/relate/explain.d.ts +199 -0
- package/dist/kernel/query/relate/index.d.ts +48 -0
- package/dist/kernel/query/relate/install.d.ts +2 -0
- package/dist/kernel/query/relate/join-on.d.ts +126 -0
- package/dist/kernel/query/relate/join-reduce.d.ts +16 -0
- package/dist/kernel/query/relate/join.d.ts +452 -0
- package/dist/kernel/query/relate/methods.d.ts +426 -0
- package/dist/kernel/query/relate/partition.d.ts +87 -0
- package/dist/kernel/query/relate/scan-methods.d.ts +163 -0
- package/dist/kernel/query/relate/traverse.d.ts +109 -0
- package/dist/kernel/query/scan-builder.d.ts +79 -176
- package/dist/kernel/query/sort-key.d.ts +52 -0
- package/dist/kernel/tx-write-gate.d.ts +77 -0
- package/dist/kernel/types.d.ts +71 -3
- package/dist/kernel/validation.d.ts +27 -10
- package/dist/kernel/vault.d.ts +9 -4
- package/dist/kernel/via/compose.d.ts +3 -0
- package/dist/kernel/via/index.d.ts +56 -0
- package/dist/kernel/via/pipeline.d.ts +48 -0
- package/dist/{ledger-F33ZVMTK.js → ledger-KZPCMVZY.js} +11 -11
- package/dist/liberate-GRLCZMW4.js +24 -0
- package/dist/link-set-JCMJ7ULP.js +30 -0
- package/dist/{managed-secret-PQYKSR6T.js → managed-secret-S3MQ6SH6.js} +10 -10
- package/dist/materialized-views/index.js +30 -23
- package/dist/{migrate-cek-5ENH64AA.js → migrate-cek-V7GKJZ7O.js} +2 -2
- package/dist/money/index.js +5 -5
- package/dist/noydb-SWQJ3MZS.js +97 -0
- package/dist/overlay-views/index.js +4 -4
- package/dist/periods/index.js +12 -12
- package/dist/pod/index.js +75 -68
- package/dist/{pod-handle-Q736KYON.js → pod-handle-WGDFB4C2.js} +9 -9
- package/dist/policy/index.js +10 -10
- package/dist/port/with/blob-strategy.d.ts +9 -0
- package/dist/port/with/collection-options.d.ts +5 -0
- package/dist/port/with/coverage-strategy.d.ts +83 -0
- package/dist/port/with/service-bus.d.ts +46 -0
- package/dist/port/with/strategies.d.ts +2 -0
- package/dist/portability/index.js +8 -8
- package/dist/{post-register-LNE2FE2A.js → post-register-SLSXIPBV.js} +6 -6
- package/dist/query/all/index.js +31 -0
- package/dist/query/index.js +20 -32
- package/dist/query/live/index.js +21 -0
- package/dist/query/live/index.js.map +1 -0
- package/dist/query/reduce/index.js +33 -0
- package/dist/query/reduce/index.js.map +1 -0
- package/dist/query/relate/index.js +56 -0
- package/dist/query/relate/index.js.map +1 -0
- package/dist/reduce/index.js +72 -18
- package/dist/reduce/index.js.map +1 -1
- package/dist/register-F3OYE7MJ.js +31 -0
- package/dist/registry-CILQFXFK.js +8 -0
- package/dist/registry-XNNYQVKV.js +8 -0
- package/dist/registry-YCDZV3VW.js +35 -0
- package/dist/registry-ZGYS33TE.js +24 -0
- package/dist/request-withdrawal-Z5NC6TXT.js +30 -0
- package/dist/{reveal-67RDQRIN.js → reveal-4BCKPEC2.js} +6 -6
- package/dist/revoke-ZL62WC2D.js +23 -0
- package/dist/satellites/index.js +1 -1
- package/dist/schema-update/index.js +2 -2
- package/dist/sealed-record/index.js +12 -12
- package/dist/search/index.js +11 -5
- package/dist/{seed-G42JYN56.js → seed-4JS2RJ4A.js} +12 -12
- package/dist/sequence/index.js +9 -9
- package/dist/session/index.js +9 -9
- package/dist/shadow/index.js +2 -2
- package/dist/signer-MBZZMXTC.js +24 -0
- package/dist/snapshots/index.js +10 -10
- package/dist/{stale-DDL7WQEZ.js → stale-TJ3DYZMQ.js} +10 -10
- package/dist/storage-SVMKRGCW.js +22 -0
- package/dist/{store-coordination-provider-MEQ2MJQG.js → store-coordination-provider-2O2VUHKW.js} +10 -10
- package/dist/sync/index.js +10 -10
- package/dist/team/index.js +17 -15
- package/dist/tiers/index.js +13 -11
- package/dist/to/index.js +2 -2
- package/dist/transactions/index.js +3 -3
- package/dist/util/index.js +1 -1
- package/dist/vault-head/index.js +8 -8
- package/dist/{verify-KOV2G5D6.js → verify-RVT67IMH.js} +5 -5
- package/dist/via/blob/index.d.ts +1 -0
- package/dist/via/geo/binding.d.ts +31 -0
- package/dist/via/geo/descriptor.d.ts +54 -0
- package/dist/via/geo/geohash.d.ts +95 -0
- package/dist/via/geo/index.d.ts +13 -0
- package/dist/via/geo/where.d.ts +50 -0
- package/dist/via/i18n/core.d.ts +1 -1
- package/dist/via/lookup/registry.d.ts +1 -1
- package/dist/via/lookup/snapshot.d.ts +3 -3
- package/dist/walk-HJ42EISE.js +21 -0
- package/dist/walk-HJ42EISE.js.map +1 -0
- package/dist/with-audit/coverage/accounting.d.ts +112 -0
- package/dist/with-audit/coverage/active.d.ts +29 -0
- package/dist/with-audit/coverage/index.d.ts +61 -0
- package/dist/with-audit/coverage/sketch.d.ts +75 -0
- package/dist/with-audit/periods/periods.d.ts +55 -7
- package/dist/with-audit/periods/reserved-collections.d.ts +3 -0
- package/dist/with-audit/periods/vault-facade.d.ts +17 -0
- package/dist/with-audit/tiers/index.d.ts +51 -0
- package/dist/with-audit/tiers/strategy.d.ts +8 -0
- package/dist/with-cargo/floor.d.ts +2 -2
- package/dist/with-commit/tx/invariants.d.ts +1 -1
- package/dist/with-commit/tx/transaction.d.ts +13 -3
- package/dist/with-formula/materialized-views/dependency-analyzer.d.ts +4 -3
- package/dist/with-formula/materialized-views/emit-memo.d.ts +40 -0
- package/dist/with-formula/materialized-views/executor.d.ts +8 -0
- package/dist/with-formula/materialized-views/index.d.ts +1 -1
- package/dist/with-formula/materialized-views/registry.d.ts +15 -0
- package/dist/with-formula/materialized-views/types.d.ts +106 -14
- package/dist/with-formula/materialized-views/window-stage.d.ts +11 -0
- package/dist/with-formula/overlay-views/types.d.ts +1 -1
- package/dist/with-formula/overlay-views/virtual-collection.d.ts +13 -4
- package/dist/with-lookup/embeddings/chunks.d.ts +79 -0
- package/dist/with-lookup/embeddings/descriptor.d.ts +21 -0
- package/dist/with-lookup/embeddings/index.d.ts +3 -0
- package/dist/with-lookup/embeddings/ivf-flat.d.ts +93 -0
- package/dist/with-lookup/embeddings/vector-index.d.ts +73 -0
- package/dist/with-lookup/embeddings/vector-set.d.ts +94 -1
- package/dist/with-lookup/embeddings/with-vector-index.d.ts +67 -0
- package/dist/with-lookup/indexing/collection-facade.d.ts +85 -2
- package/dist/with-lookup/indexing/compound-indexes.d.ts +129 -0
- package/dist/with-lookup/indexing/eager-indexes.d.ts +170 -1
- package/dist/with-lookup/indexing/index-snapshot.d.ts +62 -0
- package/dist/with-lookup/indexing/lazy-builder.d.ts +33 -0
- package/dist/with-lookup/indexing/persisted-field-indexes.d.ts +104 -0
- package/dist/with-lookup/indexing/persisted-indexes.d.ts +12 -0
- package/dist/with-lookup/indexing/sorted-indexes.d.ts +117 -0
- package/dist/with-lookup/indexing/unique-constraints.d.ts +106 -23
- package/dist/with-lookup/reduce/active.d.ts +2 -24
- package/dist/with-lookup/reduce/group-core.d.ts +43 -0
- package/dist/with-lookup/reduce/groupby.d.ts +195 -36
- package/dist/with-lookup/reduce/incremental-group.d.ts +153 -0
- package/dist/with-lookup/reduce/index.d.ts +26 -5
- package/dist/with-lookup/reduce/reducers.d.ts +255 -1
- package/dist/with-lookup/reduce/reduction.d.ts +44 -13
- package/dist/with-lookup/reduce/strategy.d.ts +43 -3
- package/dist/with-lookup/reduce/window.d.ts +262 -0
- package/dist/with-lookup/search/collection-facade.d.ts +44 -8
- package/dist/with-lookup/search/index-store.d.ts +5 -3
- package/dist/with-lookup/search/index.d.ts +4 -2
- package/dist/with-lookup/search/inverted-index.d.ts +38 -2
- package/dist/with-lookup/search/persisted-index-store.d.ts +5 -2
- package/dist/with-lookup/search/phrase.d.ts +28 -0
- package/dist/with-lookup/search/retrieve-types.d.ts +57 -1
- package/dist/with-lookup/search/serialize.d.ts +29 -3
- package/dist/with-lookup/search/strategy.d.ts +2 -6
- package/dist/with-party/directory/cover/index.d.ts +1 -1
- package/dist/with-party/directory/cover/storage.d.ts +1 -1
- package/dist/with-party/directory/cover/types.d.ts +1 -1
- package/dist/with-party/directory/index.d.ts +1 -1
- package/dist/with-party/directory/types.d.ts +1 -1
- package/dist/with-party/directory/user-envelope/api.d.ts +1 -1
- package/dist/with-party/policy/engine.d.ts +1 -1
- package/dist/with-party/policy/index.d.ts +1 -1
- package/dist/with-party/policy/presets.d.ts +1 -1
- package/dist/with-party/team/authenticators.d.ts +91 -1
- package/dist/with-party/team/index.d.ts +3 -2
- package/dist/with-party/team/keyring.d.ts +13 -6
- package/dist/with-party/team/managed-secret.d.ts +1 -1
- package/dist/with-party/team/noydb-facade.d.ts +12 -3
- package/dist/with-party/team/wrapped-deks.d.ts +4 -4
- package/dist/with-pod/format.d.ts +1 -1
- package/dist/with-pod/pod.d.ts +5 -5
- package/dist/with-shape/blobs/blob-compaction.d.ts +16 -0
- package/dist/with-shape/blobs/blob-set.d.ts +21 -2
- package/dist/with-shape/blobs/legacy-sweep.d.ts +35 -0
- package/dist/with-shape/introspection/describe.d.ts +6 -0
- package/dist/with-shape/introspection/field-meta.d.ts +18 -0
- package/dist/with-shape/introspection/types.d.ts +57 -1
- package/dist/with-shape/links/vault-facade.d.ts +1 -1
- package/dist/with-store/partitioned/index.d.ts +337 -0
- package/dist/with-sync/change-broadcast.d.ts +153 -0
- package/dist/withdraw-accessible-5NZUPAVA.js +27 -0
- package/dist/withdraw-accessible-5NZUPAVA.js.map +1 -0
- package/package.json +37 -10
- package/dist/api-TXFOVOXX.js +0 -19
- package/dist/backup-IJTB4S4M.js.map +0 -1
- package/dist/chunk-2577DKXB.js.map +0 -1
- package/dist/chunk-2C3AQB46.js.map +0 -1
- package/dist/chunk-4GVM6QZA.js.map +0 -1
- package/dist/chunk-5WDXHNSW.js.map +0 -1
- package/dist/chunk-6GOE5PGN.js.map +0 -1
- package/dist/chunk-6X6SEMEE.js.map +0 -1
- package/dist/chunk-77K4PG6P.js.map +0 -1
- package/dist/chunk-7MG2LHO5.js +0 -1616
- package/dist/chunk-7MG2LHO5.js.map +0 -1
- package/dist/chunk-7MG7SJT7.js.map +0 -1
- package/dist/chunk-7O3Y4PPD.js.map +0 -1
- package/dist/chunk-AO42KJO6.js.map +0 -1
- package/dist/chunk-ATL3ZVXT.js +0 -151
- package/dist/chunk-ATL3ZVXT.js.map +0 -1
- package/dist/chunk-BLN54W3L.js.map +0 -1
- package/dist/chunk-BM5TWITZ.js.map +0 -1
- package/dist/chunk-CUZLNGD5.js.map +0 -1
- package/dist/chunk-EQEYOJBM.js.map +0 -1
- package/dist/chunk-G56KBWFY.js.map +0 -1
- package/dist/chunk-I3ISCYT7.js +0 -159
- package/dist/chunk-I3ISCYT7.js.map +0 -1
- package/dist/chunk-KG7TZKZG.js.map +0 -1
- package/dist/chunk-KJIMGIWO.js.map +0 -1
- package/dist/chunk-KTFRCC5C.js.map +0 -1
- package/dist/chunk-KUX3OB6D.js.map +0 -1
- package/dist/chunk-MUM7IANK.js.map +0 -1
- package/dist/chunk-NA2NIJZI.js.map +0 -1
- package/dist/chunk-NSITFOCJ.js +0 -99
- package/dist/chunk-NSITFOCJ.js.map +0 -1
- package/dist/chunk-PT43Y56J.js.map +0 -1
- package/dist/chunk-QIBVIOXO.js.map +0 -1
- package/dist/chunk-RRNRNANG.js.map +0 -1
- package/dist/chunk-RTBJ5IOO.js +0 -87
- package/dist/chunk-RTBJ5IOO.js.map +0 -1
- package/dist/chunk-SKGMN35F.js.map +0 -1
- package/dist/chunk-SL3JAAKN.js.map +0 -1
- package/dist/chunk-SPXXX5E4.js.map +0 -1
- package/dist/chunk-SPYWXKJN.js.map +0 -1
- package/dist/chunk-U4FOQDY4.js.map +0 -1
- package/dist/chunk-UXVWEX5L.js.map +0 -1
- package/dist/chunk-UXWB3FPF.js.map +0 -1
- package/dist/chunk-YMUFFJCO.js.map +0 -1
- package/dist/chunk-ZN4FD4PE.js +0 -364
- package/dist/chunk-ZN4FD4PE.js.map +0 -1
- package/dist/chunk-ZORTV6NH.js.map +0 -1
- package/dist/collection-facade-4GRREZ6C.js +0 -45
- package/dist/derive-6O5SWQKN.js +0 -21
- package/dist/executor-5NIMLSKZ.js +0 -8
- package/dist/executor-AQVXV5GZ.js +0 -8
- package/dist/executor-PUAO6AKJ.js +0 -29
- package/dist/export-accessible-72EQNBMR.js +0 -22
- package/dist/extract-partition-PUYNU3UF.js +0 -37
- package/dist/find-2ABFCZX4.js +0 -10
- package/dist/issue-SIDORTSZ.js +0 -18
- package/dist/json-schema-V3M5MUCM.js.map +0 -1
- package/dist/kernel/query/join.d.ts +0 -232
- package/dist/liberate-LCDPNAG2.js +0 -24
- package/dist/link-set-FKNWAYKS.js +0 -30
- package/dist/noydb-DUXZPKSN.js +0 -90
- package/dist/register-I2DZXGAR.js +0 -31
- package/dist/registry-23WF3TGH.js +0 -8
- package/dist/registry-4AYVUNXK.js +0 -8
- package/dist/registry-VSSQPIGF.js +0 -18
- package/dist/registry-YLEWMGAC.js +0 -32
- package/dist/request-withdrawal-KFQHEZ25.js +0 -30
- package/dist/revoke-DQDZAZZM.js +0 -23
- package/dist/signer-WAMDZHEN.js +0 -24
- package/dist/storage-FLR73HHF.js +0 -22
- package/dist/walk-3UQBRMDV.js +0 -21
- package/dist/withdraw-accessible-EL5GXZBS.js +0 -27
- /package/dist/{api-TXFOVOXX.js.map → api-GVYEKSJE.js.map} +0 -0
- /package/dist/{chunk-BUE2D7PX.js.map → chunk-32YV3TJT.js.map} +0 -0
- /package/dist/{chunk-3RCJJBNR.js.map → chunk-3ELRMVJK.js.map} +0 -0
- /package/dist/{chunk-6GMZ7HEE.js.map → chunk-3F7GLNAE.js.map} +0 -0
- /package/dist/{chunk-2Y4IMKA6.js.map → chunk-3H5KLDZN.js.map} +0 -0
- /package/dist/{chunk-VTFVLCUH.js.map → chunk-3JWHAR6E.js.map} +0 -0
- /package/dist/{chunk-JBDFMYKQ.js.map → chunk-4AF3TUMP.js.map} +0 -0
- /package/dist/{chunk-J6FXAEUG.js.map → chunk-6B3VNR4P.js.map} +0 -0
- /package/dist/{chunk-TUFM4UZP.js.map → chunk-6K7DPM7D.js.map} +0 -0
- /package/dist/{chunk-K6LHRFBL.js.map → chunk-6LMQ5R26.js.map} +0 -0
- /package/dist/{chunk-XLMEZIAJ.js.map → chunk-6OWXYZK2.js.map} +0 -0
- /package/dist/{chunk-BOWNCWZT.js.map → chunk-6QSQQLSE.js.map} +0 -0
- /package/dist/{chunk-NQKIUNW5.js.map → chunk-A6IJU4TK.js.map} +0 -0
- /package/dist/{chunk-QIZPZMUI.js.map → chunk-AOWGXU6D.js.map} +0 -0
- /package/dist/{chunk-SFAWCTEM.js.map → chunk-B57AFBY2.js.map} +0 -0
- /package/dist/{chunk-GPEQUXHL.js.map → chunk-B6SJIBQK.js.map} +0 -0
- /package/dist/{chunk-Q2PU57HC.js.map → chunk-BK2HHQGN.js.map} +0 -0
- /package/dist/{collection-facade-4GRREZ6C.js.map → chunk-BKT776R5.js.map} +0 -0
- /package/dist/{chunk-FXBIP2WD.js.map → chunk-BUDAGWL5.js.map} +0 -0
- /package/dist/{chunk-BOET4NA4.js.map → chunk-CKNGS5MH.js.map} +0 -0
- /package/dist/{chunk-YSRUYAVU.js.map → chunk-DE4DH2RZ.js.map} +0 -0
- /package/dist/{chunk-6I2RQCET.js.map → chunk-DF73H4UN.js.map} +0 -0
- /package/dist/{chunk-K7NTTA6P.js.map → chunk-EOVMT6TB.js.map} +0 -0
- /package/dist/{chunk-XTXOCYOJ.js.map → chunk-FCKWQE2H.js.map} +0 -0
- /package/dist/{chunk-4OZNXTO4.js.map → chunk-FN5EBVTQ.js.map} +0 -0
- /package/dist/{chunk-NKHRDYOR.js.map → chunk-FQ5VRHIB.js.map} +0 -0
- /package/dist/{chunk-FAHMLERK.js.map → chunk-FW22ZCXT.js.map} +0 -0
- /package/dist/{chunk-RMS3NEA3.js.map → chunk-HT2AHGQI.js.map} +0 -0
- /package/dist/{chunk-CHJBLCOG.js.map → chunk-HVSCEIYL.js.map} +0 -0
- /package/dist/{chunk-GY4WYNNG.js.map → chunk-ID6Z6E66.js.map} +0 -0
- /package/dist/{chunk-EYBQEIUY.js.map → chunk-IEX7NK2K.js.map} +0 -0
- /package/dist/{chunk-KUJDV5QH.js.map → chunk-ISZQJBML.js.map} +0 -0
- /package/dist/{chunk-LWBCUYZW.js.map → chunk-IT22PWKV.js.map} +0 -0
- /package/dist/{chunk-7V4TP3AF.js.map → chunk-J6UOHJY5.js.map} +0 -0
- /package/dist/{chunk-JMGDHKQF.js.map → chunk-JCN44NCY.js.map} +0 -0
- /package/dist/{chunk-CARABLSQ.js.map → chunk-K6W7BVZ6.js.map} +0 -0
- /package/dist/{chunk-453F654R.js.map → chunk-L7DOS3TE.js.map} +0 -0
- /package/dist/{chunk-WEQEYLCS.js.map → chunk-LGRLME4M.js.map} +0 -0
- /package/dist/{chunk-RMF67KCG.js.map → chunk-LQ4ZHOKP.js.map} +0 -0
- /package/dist/{chunk-ZVO4QVPD.js.map → chunk-M522UYZ2.js.map} +0 -0
- /package/dist/{chunk-2N4GY74U.js.map → chunk-MTL7MXGR.js.map} +0 -0
- /package/dist/{chunk-TFR7DSOV.js.map → chunk-MVZ2TPVP.js.map} +0 -0
- /package/dist/{chunk-CPWQB3N5.js.map → chunk-N5DNADLQ.js.map} +0 -0
- /package/dist/{chunk-ELNXJMGB.js.map → chunk-NNARWO72.js.map} +0 -0
- /package/dist/{chunk-6YXCPL4T.js.map → chunk-PDCG6PR5.js.map} +0 -0
- /package/dist/{chunk-REDOOY2Q.js.map → chunk-PSIV7CJV.js.map} +0 -0
- /package/dist/{chunk-ANATMFIO.js.map → chunk-QWFHIOD2.js.map} +0 -0
- /package/dist/{chunk-X2DLENDQ.js.map → chunk-QWGU66MP.js.map} +0 -0
- /package/dist/{chunk-BSFNRLK2.js.map → chunk-S57HTZ6X.js.map} +0 -0
- /package/dist/{chunk-SZJ3DLZA.js.map → chunk-SEE332EV.js.map} +0 -0
- /package/dist/{chunk-YYP7WSEB.js.map → chunk-SI3V7D4G.js.map} +0 -0
- /package/dist/{chunk-UGTBXF5U.js.map → chunk-SOIQ4MM4.js.map} +0 -0
- /package/dist/{chunk-VXGSWL6L.js.map → chunk-SYVZW77S.js.map} +0 -0
- /package/dist/{chunk-MVMXZYXT.js.map → chunk-TKUOEU2F.js.map} +0 -0
- /package/dist/{chunk-SMH6SRX7.js.map → chunk-TROR3ALR.js.map} +0 -0
- /package/dist/{chunk-DGOZ4UZD.js.map → chunk-VNNRUGMM.js.map} +0 -0
- /package/dist/{chunk-HDOU6I2Y.js.map → chunk-VNPEWFPD.js.map} +0 -0
- /package/dist/{chunk-L7CIOOBW.js.map → chunk-WNJ4AVGE.js.map} +0 -0
- /package/dist/{chunk-FMZY5Q6L.js.map → chunk-WX5ADGTZ.js.map} +0 -0
- /package/dist/{chunk-Q7HZX3IF.js.map → chunk-X4773RBR.js.map} +0 -0
- /package/dist/{chunk-ANSIZYEG.js.map → chunk-YNIUIERI.js.map} +0 -0
- /package/dist/{chunk-BZ3534YM.js.map → chunk-ZUVBC32X.js.map} +0 -0
- /package/dist/{chunk-L742JPKZ.js.map → chunk-ZXABPVM6.js.map} +0 -0
- /package/dist/{classified-marker-LI2SF2E4.js.map → classified-marker-W3USLL5M.js.map} +0 -0
- /package/dist/{computed-VPOKQK4N.js.map → collection-facade-QU6IJBN3.js.map} +0 -0
- /package/dist/{derive-6O5SWQKN.js.map → computed-TPFBX7U4.js.map} +0 -0
- /package/dist/{dead-filter-TSWZQRR5.js.map → dead-filter-U2UYKSZL.js.map} +0 -0
- /package/dist/{delegation-OVIFFPG4.js.map → delegation-S3AEPW2T.js.map} +0 -0
- /package/dist/{enclave-KJOTOH7X.js.map → derive-OX7F6TGG.js.map} +0 -0
- /package/dist/{dispatch-WC6X2M6C.js.map → dispatch-3CQDJV5Q.js.map} +0 -0
- /package/dist/{dispatch-S73TK3IY.js.map → dispatch-RH4LHKBH.js.map} +0 -0
- /package/dist/{executor-5NIMLSKZ.js.map → enclave-27SMF6GF.js.map} +0 -0
- /package/dist/{executor-AQVXV5GZ.js.map → executor-B6SRO2QS.js.map} +0 -0
- /package/dist/{executor-PUAO6AKJ.js.map → executor-BI5CHWRY.js.map} +0 -0
- /package/dist/{export-accessible-72EQNBMR.js.map → executor-RBKM5W5K.js.map} +0 -0
- /package/dist/{extract-partition-PUYNU3UF.js.map → export-accessible-VMA3YM5V.js.map} +0 -0
- /package/dist/{find-2ABFCZX4.js.map → extract-partition-NF7PXGPP.js.map} +0 -0
- /package/dist/{fanout-sidecar-WUFXNYP4.js.map → fanout-sidecar-OT6RYLOL.js.map} +0 -0
- /package/dist/{issue-SIDORTSZ.js.map → find-LZMP26KF.js.map} +0 -0
- /package/dist/{ledger-F33ZVMTK.js.map → issue-IHARXWW5.js.map} +0 -0
- /package/dist/{liberate-LCDPNAG2.js.map → ledger-KZPCMVZY.js.map} +0 -0
- /package/dist/{link-set-FKNWAYKS.js.map → liberate-GRLCZMW4.js.map} +0 -0
- /package/dist/{managed-secret-PQYKSR6T.js.map → link-set-JCMJ7ULP.js.map} +0 -0
- /package/dist/{noydb-DUXZPKSN.js.map → managed-secret-S3MQ6SH6.js.map} +0 -0
- /package/dist/{migrate-cek-5ENH64AA.js.map → migrate-cek-V7GKJZ7O.js.map} +0 -0
- /package/dist/{register-I2DZXGAR.js.map → noydb-SWQJ3MZS.js.map} +0 -0
- /package/dist/{pod-handle-Q736KYON.js.map → pod-handle-WGDFB4C2.js.map} +0 -0
- /package/dist/{post-register-LNE2FE2A.js.map → post-register-SLSXIPBV.js.map} +0 -0
- /package/dist/{registry-23WF3TGH.js.map → query/all/index.js.map} +0 -0
- /package/dist/{registry-4AYVUNXK.js.map → register-F3OYE7MJ.js.map} +0 -0
- /package/dist/{registry-VSSQPIGF.js.map → registry-CILQFXFK.js.map} +0 -0
- /package/dist/{registry-YLEWMGAC.js.map → registry-XNNYQVKV.js.map} +0 -0
- /package/dist/{request-withdrawal-KFQHEZ25.js.map → registry-YCDZV3VW.js.map} +0 -0
- /package/dist/{revoke-DQDZAZZM.js.map → registry-ZGYS33TE.js.map} +0 -0
- /package/dist/{signer-WAMDZHEN.js.map → request-withdrawal-Z5NC6TXT.js.map} +0 -0
- /package/dist/{reveal-67RDQRIN.js.map → reveal-4BCKPEC2.js.map} +0 -0
- /package/dist/{stale-DDL7WQEZ.js.map → revoke-ZL62WC2D.js.map} +0 -0
- /package/dist/{seed-G42JYN56.js.map → seed-4JS2RJ4A.js.map} +0 -0
- /package/dist/{storage-FLR73HHF.js.map → signer-MBZZMXTC.js.map} +0 -0
- /package/dist/{walk-3UQBRMDV.js.map → stale-TJ3DYZMQ.js.map} +0 -0
- /package/dist/{withdraw-accessible-EL5GXZBS.js.map → storage-SVMKRGCW.js.map} +0 -0
- /package/dist/{store-coordination-provider-MEQ2MJQG.js.map → store-coordination-provider-2O2VUHKW.js.map} +0 -0
- /package/dist/{verify-KOV2G5D6.js.map → verify-RVT67IMH.js.map} +0 -0
package/dist/index.js
CHANGED
|
@@ -1,32 +1,20 @@
|
|
|
1
|
+
import {
|
|
2
|
+
LinkEndpointError
|
|
3
|
+
} from "./chunk-3F7GLNAE.js";
|
|
1
4
|
import {
|
|
2
5
|
persistSchemaIfNeeded
|
|
3
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-6LMQ5R26.js";
|
|
4
7
|
import {
|
|
5
|
-
|
|
6
|
-
|
|
8
|
+
ComputedFieldError,
|
|
9
|
+
evalComputedFields
|
|
10
|
+
} from "./chunk-IT22PWKV.js";
|
|
7
11
|
import {
|
|
8
12
|
WithdrawalRequestError,
|
|
9
13
|
approveWithdrawal,
|
|
10
14
|
listWithdrawalRequests,
|
|
11
15
|
rejectWithdrawal,
|
|
12
16
|
requestWithdrawal
|
|
13
|
-
} from "./chunk-
|
|
14
|
-
import {
|
|
15
|
-
ComputedFieldError,
|
|
16
|
-
evalComputedFields
|
|
17
|
-
} from "./chunk-LWBCUYZW.js";
|
|
18
|
-
import {
|
|
19
|
-
DEFAULT_FRESHNESS_MS,
|
|
20
|
-
PERSONAL_POLICY,
|
|
21
|
-
STRICT_POLICY,
|
|
22
|
-
checkGate,
|
|
23
|
-
describeGate,
|
|
24
|
-
mergePolicy
|
|
25
|
-
} from "./chunk-SPYWXKJN.js";
|
|
26
|
-
import "./chunk-GJW4HX2O.js";
|
|
27
|
-
import {
|
|
28
|
-
UserApi
|
|
29
|
-
} from "./chunk-MUM7IANK.js";
|
|
17
|
+
} from "./chunk-FCKWQE2H.js";
|
|
30
18
|
import {
|
|
31
19
|
routeStore,
|
|
32
20
|
withCache,
|
|
@@ -43,56 +31,60 @@ import {
|
|
|
43
31
|
isMoneyString,
|
|
44
32
|
moneyNumber,
|
|
45
33
|
mulRate
|
|
46
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-ID6Z6E66.js";
|
|
47
35
|
import {
|
|
48
36
|
COVER_FIELDS,
|
|
49
37
|
DEFAULT_COVER_SCHEMA,
|
|
50
38
|
resolveSchema
|
|
51
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-B2YY6WDD.js";
|
|
52
40
|
import {
|
|
53
41
|
additiveOnly,
|
|
54
42
|
blindUpdate,
|
|
55
43
|
coordinatedCutover,
|
|
56
44
|
lockSchema
|
|
57
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-HT2AHGQI.js";
|
|
58
46
|
import "./chunk-ZVF37PKE.js";
|
|
59
47
|
import {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
48
|
+
DEFAULT_FRESHNESS_MS,
|
|
49
|
+
PERSONAL_POLICY,
|
|
50
|
+
STRICT_POLICY,
|
|
51
|
+
checkGate,
|
|
52
|
+
describeGate,
|
|
53
|
+
mergePolicy
|
|
54
|
+
} from "./chunk-F7XGHL5O.js";
|
|
55
|
+
import "./chunk-GJW4HX2O.js";
|
|
56
|
+
import {
|
|
57
|
+
UserApi
|
|
58
|
+
} from "./chunk-4MXI3ODD.js";
|
|
63
59
|
import {
|
|
64
60
|
decryptExtractedPartition,
|
|
65
61
|
withCargo
|
|
66
|
-
} from "./chunk-
|
|
62
|
+
} from "./chunk-6B3VNR4P.js";
|
|
67
63
|
import {
|
|
68
64
|
diffVault
|
|
69
65
|
} from "./chunk-LFUID7OW.js";
|
|
70
|
-
import "./chunk-
|
|
66
|
+
import "./chunk-3ELRMVJK.js";
|
|
71
67
|
import {
|
|
72
68
|
createDeedOwner,
|
|
73
69
|
isDeedVault,
|
|
74
70
|
liberateVault,
|
|
75
71
|
loadDeedMarker
|
|
76
|
-
} from "./chunk-
|
|
72
|
+
} from "./chunk-HVSCEIYL.js";
|
|
77
73
|
import {
|
|
78
74
|
withdrawAccessibleData
|
|
79
|
-
} from "./chunk-
|
|
75
|
+
} from "./chunk-S57HTZ6X.js";
|
|
80
76
|
import {
|
|
81
77
|
exportAccessibleData
|
|
82
|
-
} from "./chunk-
|
|
78
|
+
} from "./chunk-WNJ4AVGE.js";
|
|
83
79
|
import {
|
|
84
80
|
applyListProjection
|
|
85
81
|
} from "./chunk-VG2ZSFYD.js";
|
|
86
|
-
import {
|
|
87
|
-
withDerivation,
|
|
88
|
-
withRollup
|
|
89
|
-
} from "./chunk-BUE2D7PX.js";
|
|
90
82
|
import {
|
|
91
83
|
withMaterializedView
|
|
92
|
-
} from "./chunk-
|
|
93
|
-
import "./chunk-
|
|
94
|
-
import "./chunk-
|
|
95
|
-
import "./chunk-
|
|
84
|
+
} from "./chunk-X25NWUZB.js";
|
|
85
|
+
import "./chunk-QBBUZ3I3.js";
|
|
86
|
+
import "./chunk-NWHBJQAL.js";
|
|
87
|
+
import "./chunk-WX5ADGTZ.js";
|
|
96
88
|
import {
|
|
97
89
|
MoneyCurrencyError,
|
|
98
90
|
MoneyPrecisionError,
|
|
@@ -101,19 +93,50 @@ import {
|
|
|
101
93
|
isMoneyDescriptor,
|
|
102
94
|
money,
|
|
103
95
|
scaleForCurrency
|
|
104
|
-
} from "./chunk-
|
|
96
|
+
} from "./chunk-WY2XXTET.js";
|
|
105
97
|
import {
|
|
106
98
|
withOverlayedView
|
|
107
|
-
} from "./chunk-
|
|
108
|
-
import "./chunk-
|
|
99
|
+
} from "./chunk-B57AFBY2.js";
|
|
100
|
+
import "./chunk-BK2HHQGN.js";
|
|
109
101
|
import {
|
|
110
102
|
PresenceHandle,
|
|
111
103
|
SyncEngine,
|
|
112
104
|
SyncTransaction
|
|
113
|
-
} from "./chunk-
|
|
105
|
+
} from "./chunk-N5DNADLQ.js";
|
|
114
106
|
import {
|
|
115
107
|
isDiscriminant
|
|
116
108
|
} from "./chunk-PY4KJPYU.js";
|
|
109
|
+
import {
|
|
110
|
+
classified,
|
|
111
|
+
luhnCheck
|
|
112
|
+
} from "./chunk-BUDAGWL5.js";
|
|
113
|
+
import {
|
|
114
|
+
immutableGuard,
|
|
115
|
+
transitionGuard,
|
|
116
|
+
withGuard
|
|
117
|
+
} from "./chunk-SI3V7D4G.js";
|
|
118
|
+
import "./chunk-FN5EBVTQ.js";
|
|
119
|
+
import "./chunk-VNNRUGMM.js";
|
|
120
|
+
import "./chunk-JK733I5V.js";
|
|
121
|
+
import {
|
|
122
|
+
CollectionFrame,
|
|
123
|
+
VaultFrame
|
|
124
|
+
} from "./chunk-6OWXYZK2.js";
|
|
125
|
+
import {
|
|
126
|
+
withDerivation,
|
|
127
|
+
withRollup
|
|
128
|
+
} from "./chunk-32YV3TJT.js";
|
|
129
|
+
import {
|
|
130
|
+
withLazy
|
|
131
|
+
} from "./chunk-ULUMAZ5S.js";
|
|
132
|
+
import "./chunk-T52GX4SA.js";
|
|
133
|
+
import {
|
|
134
|
+
reduceRecords
|
|
135
|
+
} from "./chunk-CF5UU4S7.js";
|
|
136
|
+
import {
|
|
137
|
+
mergeCrdtStates,
|
|
138
|
+
resolveCrdtSnapshot
|
|
139
|
+
} from "./chunk-4GPE63GU.js";
|
|
117
140
|
import {
|
|
118
141
|
createPodStore,
|
|
119
142
|
followRedirects,
|
|
@@ -121,7 +144,7 @@ import {
|
|
|
121
144
|
signRedirect,
|
|
122
145
|
verifyRedirect,
|
|
123
146
|
wrapPodStore
|
|
124
|
-
} from "./chunk-
|
|
147
|
+
} from "./chunk-LGRLME4M.js";
|
|
125
148
|
import {
|
|
126
149
|
Collection,
|
|
127
150
|
ELEVATION_AUDIT_COLLECTION,
|
|
@@ -138,107 +161,47 @@ import {
|
|
|
138
161
|
ref,
|
|
139
162
|
refArray,
|
|
140
163
|
withArchive
|
|
141
|
-
} from "./chunk-
|
|
164
|
+
} from "./chunk-T2LBQ5DV.js";
|
|
165
|
+
import {
|
|
166
|
+
LinkIntegrityError,
|
|
167
|
+
isLinkCollectionName
|
|
168
|
+
} from "./chunk-AOWGXU6D.js";
|
|
169
|
+
import "./chunk-6K7DPM7D.js";
|
|
170
|
+
import "./chunk-TROR3ALR.js";
|
|
142
171
|
import {
|
|
143
172
|
deriveSchemaManifest,
|
|
144
173
|
loadSchemaManifestEntry
|
|
145
|
-
} from "./chunk-
|
|
174
|
+
} from "./chunk-SYVZW77S.js";
|
|
146
175
|
import {
|
|
147
176
|
MANIFEST_COLLECTION,
|
|
148
177
|
isManifestReservedCollection
|
|
149
178
|
} from "./chunk-EPFF7LOX.js";
|
|
150
|
-
import
|
|
151
|
-
|
|
152
|
-
isLinkCollectionName
|
|
153
|
-
} from "./chunk-QIZPZMUI.js";
|
|
154
|
-
import "./chunk-TUFM4UZP.js";
|
|
155
|
-
import "./chunk-SMH6SRX7.js";
|
|
156
|
-
import "./chunk-453F654R.js";
|
|
157
|
-
import "./chunk-SPXXX5E4.js";
|
|
179
|
+
import "./chunk-L7DOS3TE.js";
|
|
180
|
+
import "./chunk-6LNL42F5.js";
|
|
158
181
|
import "./chunk-GYGLAVCX.js";
|
|
159
182
|
import "./chunk-6LJY7X5A.js";
|
|
160
|
-
import "./chunk-
|
|
161
|
-
import "./chunk-
|
|
162
|
-
import "./chunk-BZ3534YM.js";
|
|
183
|
+
import "./chunk-UPD5NWI5.js";
|
|
184
|
+
import "./chunk-ZUVBC32X.js";
|
|
163
185
|
import {
|
|
164
186
|
NO_CARGO
|
|
165
|
-
} from "./chunk-
|
|
187
|
+
} from "./chunk-A6IJU4TK.js";
|
|
188
|
+
import "./chunk-RXLYKVTF.js";
|
|
166
189
|
import {
|
|
167
190
|
MemoryRecipientSealer,
|
|
168
191
|
MemorySealer,
|
|
169
192
|
aesGcmOpen,
|
|
170
193
|
parseRsaOaepTlv,
|
|
171
194
|
sealRsaOaepTlv
|
|
172
|
-
} from "./chunk-
|
|
173
|
-
import "./chunk-
|
|
174
|
-
import "./chunk-
|
|
175
|
-
import
|
|
176
|
-
NO_SEQUENCE,
|
|
177
|
-
SequenceStore,
|
|
178
|
-
compileSequenceFormat,
|
|
179
|
-
resolveSequenceKey,
|
|
180
|
-
withSequence
|
|
181
|
-
} from "./chunk-ZVO4QVPD.js";
|
|
182
|
-
import {
|
|
183
|
-
CustodyApi,
|
|
184
|
-
NO_CUSTODY,
|
|
185
|
-
withCustody
|
|
186
|
-
} from "./chunk-GPEQUXHL.js";
|
|
187
|
-
import {
|
|
188
|
-
isViaFieldSpec,
|
|
189
|
-
via
|
|
190
|
-
} from "./chunk-2C3AQB46.js";
|
|
191
|
-
import "./chunk-TFMM5DBB.js";
|
|
192
|
-
import "./chunk-RTBJ5IOO.js";
|
|
193
|
-
import {
|
|
194
|
-
ClassifiedNeverStoredError,
|
|
195
|
-
ClassifiedValidationError,
|
|
196
|
-
isClassifiedFieldSpec,
|
|
197
|
-
isClassifiedGroup,
|
|
198
|
-
resolveClassifiedFields
|
|
199
|
-
} from "./chunk-5VCRVKOZ.js";
|
|
200
|
-
import "./chunk-VYYM3MEN.js";
|
|
201
|
-
import {
|
|
202
|
-
derivePersistedSchema,
|
|
203
|
-
isZodSchema
|
|
204
|
-
} from "./chunk-REDOOY2Q.js";
|
|
205
|
-
import "./chunk-Y2NBBT6K.js";
|
|
206
|
-
import {
|
|
207
|
-
SCHEMAS_COLLECTION,
|
|
208
|
-
loadPersistedSchema,
|
|
209
|
-
savePersistedSchema
|
|
210
|
-
} from "./chunk-2Y4IMKA6.js";
|
|
211
|
-
import "./chunk-CARABLSQ.js";
|
|
212
|
-
import {
|
|
213
|
-
buildLookupSnapshot
|
|
214
|
-
} from "./chunk-U4FOQDY4.js";
|
|
215
|
-
import "./chunk-SKGMN35F.js";
|
|
195
|
+
} from "./chunk-ENAG3IY7.js";
|
|
196
|
+
import "./chunk-3JWHAR6E.js";
|
|
197
|
+
import "./chunk-K6W7BVZ6.js";
|
|
198
|
+
import "./chunk-MLPHLJIQ.js";
|
|
216
199
|
import {
|
|
217
200
|
INDEXED_STORE_POLICY,
|
|
218
201
|
POD_STORE_POLICY,
|
|
219
202
|
SyncScheduler
|
|
220
203
|
} from "./chunk-T7IR4N2S.js";
|
|
221
|
-
import
|
|
222
|
-
CONSENT_AUDIT_COLLECTION
|
|
223
|
-
} from "./chunk-NKHRDYOR.js";
|
|
224
|
-
import "./chunk-PEOZ34EM.js";
|
|
225
|
-
import "./chunk-PT43Y56J.js";
|
|
226
|
-
import "./chunk-GHVIKOHT.js";
|
|
227
|
-
import {
|
|
228
|
-
PERIODS_COLLECTION
|
|
229
|
-
} from "./chunk-FAHMLERK.js";
|
|
230
|
-
import {
|
|
231
|
-
immutableGuard,
|
|
232
|
-
transitionGuard,
|
|
233
|
-
withGuard
|
|
234
|
-
} from "./chunk-YYP7WSEB.js";
|
|
235
|
-
import "./chunk-4OZNXTO4.js";
|
|
236
|
-
import "./chunk-DGOZ4UZD.js";
|
|
237
|
-
import "./chunk-JK733I5V.js";
|
|
238
|
-
import {
|
|
239
|
-
CollectionFrame,
|
|
240
|
-
VaultFrame
|
|
241
|
-
} from "./chunk-XLMEZIAJ.js";
|
|
204
|
+
import "./chunk-X4773RBR.js";
|
|
242
205
|
import "./chunk-SMY5X46Z.js";
|
|
243
206
|
import "./chunk-DZFQVICS.js";
|
|
244
207
|
import {
|
|
@@ -256,7 +219,7 @@ import {
|
|
|
256
219
|
verifyPodHeader,
|
|
257
220
|
verifyRecord,
|
|
258
221
|
writePod
|
|
259
|
-
} from "./chunk-
|
|
222
|
+
} from "./chunk-HBPPGWUM.js";
|
|
260
223
|
import {
|
|
261
224
|
COVER_RECORD_ID,
|
|
262
225
|
isCover,
|
|
@@ -264,39 +227,141 @@ import {
|
|
|
264
227
|
readCover,
|
|
265
228
|
saveCover,
|
|
266
229
|
validateCoverInput
|
|
267
|
-
} from "./chunk-
|
|
230
|
+
} from "./chunk-IUWCVHQ7.js";
|
|
268
231
|
import {
|
|
269
232
|
TxCollection,
|
|
270
233
|
TxContext,
|
|
271
234
|
TxVault,
|
|
272
235
|
runTransaction
|
|
273
|
-
} from "./chunk-
|
|
236
|
+
} from "./chunk-5FDLC6G7.js";
|
|
274
237
|
import "./chunk-5D2ALSM5.js";
|
|
275
238
|
import {
|
|
276
239
|
NO_SEARCH,
|
|
277
240
|
tokenize,
|
|
278
241
|
withSearch
|
|
279
|
-
} from "./chunk-
|
|
242
|
+
} from "./chunk-I3JDRCMW.js";
|
|
280
243
|
import {
|
|
281
244
|
fuseRetrieval
|
|
282
245
|
} from "./chunk-AURFOK3D.js";
|
|
283
|
-
import "./chunk-6YXCPL4T.js";
|
|
284
246
|
import {
|
|
285
|
-
|
|
247
|
+
NO_SEQUENCE,
|
|
248
|
+
SequenceStore,
|
|
249
|
+
compileSequenceFormat,
|
|
250
|
+
resolveSequenceKey,
|
|
251
|
+
withSequence
|
|
252
|
+
} from "./chunk-M522UYZ2.js";
|
|
253
|
+
import {
|
|
254
|
+
CustodyApi,
|
|
255
|
+
NO_CUSTODY,
|
|
256
|
+
withCustody
|
|
257
|
+
} from "./chunk-B6SJIBQK.js";
|
|
258
|
+
import {
|
|
259
|
+
isViaFieldSpec,
|
|
260
|
+
via
|
|
261
|
+
} from "./chunk-UD5EVGZ7.js";
|
|
262
|
+
import "./chunk-TFMM5DBB.js";
|
|
263
|
+
import "./chunk-MDWKM2XC.js";
|
|
264
|
+
import "./chunk-VYYM3MEN.js";
|
|
265
|
+
import {
|
|
266
|
+
derivePersistedSchema,
|
|
267
|
+
isZodSchema
|
|
268
|
+
} from "./chunk-PSIV7CJV.js";
|
|
269
|
+
import "./chunk-Y2NBBT6K.js";
|
|
270
|
+
import {
|
|
271
|
+
SCHEMAS_COLLECTION,
|
|
272
|
+
loadPersistedSchema,
|
|
273
|
+
savePersistedSchema
|
|
274
|
+
} from "./chunk-3H5KLDZN.js";
|
|
275
|
+
import {
|
|
276
|
+
buildLookupSnapshot
|
|
277
|
+
} from "./chunk-FH2L2E34.js";
|
|
278
|
+
import {
|
|
279
|
+
ClassifiedNeverStoredError,
|
|
280
|
+
ClassifiedValidationError,
|
|
281
|
+
isClassifiedFieldSpec,
|
|
282
|
+
isClassifiedGroup,
|
|
283
|
+
resolveClassifiedFields
|
|
284
|
+
} from "./chunk-QOOUUR4A.js";
|
|
285
|
+
import {
|
|
286
|
+
DEFAULT_INDEX_MIN_VECTORS,
|
|
287
|
+
withVectorIndex
|
|
288
|
+
} from "./chunk-NYMLINRP.js";
|
|
289
|
+
import "./chunk-HBRLNOHL.js";
|
|
290
|
+
import "./chunk-66TQOPFM.js";
|
|
291
|
+
import {
|
|
292
|
+
Lru,
|
|
293
|
+
estimateRecordBytes,
|
|
294
|
+
parseBytes
|
|
295
|
+
} from "./chunk-V4PXLYWM.js";
|
|
296
|
+
import "./chunk-XZHEOSQ2.js";
|
|
297
|
+
import "./chunk-PVEWA2DU.js";
|
|
298
|
+
import {
|
|
299
|
+
CONSENT_AUDIT_COLLECTION
|
|
300
|
+
} from "./chunk-FQ5VRHIB.js";
|
|
301
|
+
import "./chunk-PEOZ34EM.js";
|
|
302
|
+
import "./chunk-RHVMZSUU.js";
|
|
303
|
+
import "./chunk-NRT6QZQB.js";
|
|
304
|
+
import "./chunk-GHVIKOHT.js";
|
|
305
|
+
import {
|
|
306
|
+
PERIODS_COLLECTION
|
|
307
|
+
} from "./chunk-FW22ZCXT.js";
|
|
308
|
+
import "./chunk-PDCG6PR5.js";
|
|
309
|
+
import "./chunk-BKT776R5.js";
|
|
310
|
+
import {
|
|
311
|
+
CollectionIndexes
|
|
312
|
+
} from "./chunk-YSK2CU2Q.js";
|
|
313
|
+
import {
|
|
314
|
+
ALL_PARTITIONS,
|
|
315
|
+
describePartitionScope,
|
|
316
|
+
partitionsInScope,
|
|
317
|
+
resolvePartitionScope
|
|
318
|
+
} from "./chunk-CY2CYVWZ.js";
|
|
319
|
+
import {
|
|
286
320
|
Query,
|
|
287
|
-
ScanBuilder,
|
|
288
|
-
buildLiveQuery,
|
|
321
|
+
ScanBuilder as ScanBuilder2,
|
|
289
322
|
executePlan
|
|
290
|
-
} from "./chunk-
|
|
323
|
+
} from "./chunk-TOPYQ6GA.js";
|
|
324
|
+
import {
|
|
325
|
+
buildLiveQuery
|
|
326
|
+
} from "./chunk-FQ54DWUQ.js";
|
|
327
|
+
import "./chunk-FXQBGFOX.js";
|
|
328
|
+
import "./chunk-F2TDU7MQ.js";
|
|
329
|
+
import "./chunk-ORDURZBU.js";
|
|
330
|
+
import "./chunk-SUZKW6UR.js";
|
|
331
|
+
import "./chunk-BJ2IXQ5Q.js";
|
|
332
|
+
import "./chunk-VHM7HCKB.js";
|
|
333
|
+
import "./chunk-XBKH4FOC.js";
|
|
334
|
+
import {
|
|
335
|
+
explainPlan,
|
|
336
|
+
renderExplainText
|
|
337
|
+
} from "./chunk-ZSX4S5XB.js";
|
|
291
338
|
import {
|
|
339
|
+
DEFAULT_CROSS_JOIN_MAX_ROWS,
|
|
292
340
|
DEFAULT_JOIN_MAX_ROWS,
|
|
293
341
|
applyJoins
|
|
294
|
-
} from "./chunk-
|
|
342
|
+
} from "./chunk-4I522ERM.js";
|
|
343
|
+
import "./chunk-MKXXMNJH.js";
|
|
344
|
+
import "./chunk-LGNDFRYC.js";
|
|
345
|
+
import {
|
|
346
|
+
ScanBuilder
|
|
347
|
+
} from "./chunk-F24ZZTHQ.js";
|
|
348
|
+
import "./chunk-F6NCB7KT.js";
|
|
349
|
+
import {
|
|
350
|
+
sortRecords
|
|
351
|
+
} from "./chunk-7JE7BDYJ.js";
|
|
352
|
+
import "./chunk-3TDUWVWB.js";
|
|
353
|
+
import "./chunk-5O7D6ZTW.js";
|
|
354
|
+
import {
|
|
355
|
+
evaluateClause,
|
|
356
|
+
evaluateFieldClause,
|
|
357
|
+
evaluateOperator,
|
|
358
|
+
readPath
|
|
359
|
+
} from "./chunk-HLEK5VAN.js";
|
|
295
360
|
import {
|
|
296
361
|
importExternalObjects,
|
|
297
362
|
memoryObjectProjection
|
|
298
363
|
} from "./chunk-4Q6HSHHL.js";
|
|
299
|
-
import "./chunk-
|
|
364
|
+
import "./chunk-GF5BZ7D4.js";
|
|
300
365
|
import {
|
|
301
366
|
BLOB_CHUNKS_COLLECTION,
|
|
302
367
|
BLOB_COLLECTION,
|
|
@@ -313,44 +378,17 @@ import {
|
|
|
313
378
|
getIntent,
|
|
314
379
|
isPreCompressed,
|
|
315
380
|
sweepBlobIntents
|
|
316
|
-
} from "./chunk-
|
|
317
|
-
import "./chunk-
|
|
318
|
-
import {
|
|
319
|
-
CollectionIndexes
|
|
320
|
-
} from "./chunk-I3ISCYT7.js";
|
|
321
|
-
import {
|
|
322
|
-
withLazy
|
|
323
|
-
} from "./chunk-ULUMAZ5S.js";
|
|
324
|
-
import "./chunk-66TQOPFM.js";
|
|
325
|
-
import {
|
|
326
|
-
Lru,
|
|
327
|
-
estimateRecordBytes,
|
|
328
|
-
parseBytes
|
|
329
|
-
} from "./chunk-V4PXLYWM.js";
|
|
330
|
-
import "./chunk-ZN4FD4PE.js";
|
|
331
|
-
import "./chunk-XZHEOSQ2.js";
|
|
332
|
-
import "./chunk-YMUFFJCO.js";
|
|
333
|
-
import "./chunk-ATL3ZVXT.js";
|
|
334
|
-
import {
|
|
335
|
-
evaluateClause,
|
|
336
|
-
evaluateFieldClause,
|
|
337
|
-
readPath
|
|
338
|
-
} from "./chunk-NSITFOCJ.js";
|
|
339
|
-
import {
|
|
340
|
-
mergeCrdtStates,
|
|
341
|
-
resolveCrdtSnapshot
|
|
342
|
-
} from "./chunk-4GPE63GU.js";
|
|
343
|
-
import "./chunk-PVEWA2DU.js";
|
|
344
|
-
import "./chunk-K7NTTA6P.js";
|
|
381
|
+
} from "./chunk-ANWPSTZU.js";
|
|
382
|
+
import "./chunk-EOVMT6TB.js";
|
|
345
383
|
import {
|
|
346
384
|
dictKey,
|
|
347
385
|
staticDict
|
|
348
|
-
} from "./chunk-
|
|
386
|
+
} from "./chunk-TKUOEU2F.js";
|
|
349
387
|
import {
|
|
350
388
|
DICT_COLLECTION_PREFIX,
|
|
351
389
|
LookupHandle,
|
|
352
390
|
dictCollectionName
|
|
353
|
-
} from "./chunk-
|
|
391
|
+
} from "./chunk-DF73H4UN.js";
|
|
354
392
|
import {
|
|
355
393
|
applyI18nLocale,
|
|
356
394
|
enforceScript,
|
|
@@ -365,15 +403,16 @@ import {
|
|
|
365
403
|
resolvePolicy,
|
|
366
404
|
setAtPathInPlace,
|
|
367
405
|
validateI18nTextValue
|
|
368
|
-
} from "./chunk-
|
|
406
|
+
} from "./chunk-GHLTDZRS.js";
|
|
369
407
|
import {
|
|
370
|
-
installViaBinder
|
|
371
|
-
|
|
408
|
+
installViaBinder,
|
|
409
|
+
isViaPrefixProbe
|
|
410
|
+
} from "./chunk-Z5HTYMMQ.js";
|
|
372
411
|
import {
|
|
373
412
|
MemoryDeviceSeal,
|
|
374
413
|
beginEchoUnlock,
|
|
375
414
|
withTeam
|
|
376
|
-
} from "./chunk-
|
|
415
|
+
} from "./chunk-IEX7NK2K.js";
|
|
377
416
|
import {
|
|
378
417
|
MAGIC_LINK_GRANTS_COLLECTION,
|
|
379
418
|
NO_TEAM,
|
|
@@ -402,13 +441,13 @@ import {
|
|
|
402
441
|
unwrapDeksFromPaperEntry,
|
|
403
442
|
unwrapMagicLinkGrant,
|
|
404
443
|
writeMagicLinkGrant
|
|
405
|
-
} from "./chunk-
|
|
444
|
+
} from "./chunk-ZE4CHIED.js";
|
|
406
445
|
import {
|
|
407
446
|
META_COLLECTION,
|
|
408
447
|
POLICY_RECORD_ID,
|
|
409
448
|
loadVaultPolicy,
|
|
410
449
|
saveVaultPolicy
|
|
411
|
-
} from "./chunk-
|
|
450
|
+
} from "./chunk-DC5QVPV7.js";
|
|
412
451
|
import {
|
|
413
452
|
DEFAULT_ECHO_MIN_WORD_LENGTH,
|
|
414
453
|
DEFAULT_ECHO_PROMPT_MIN_WORDS,
|
|
@@ -434,7 +473,7 @@ import {
|
|
|
434
473
|
validateSecret,
|
|
435
474
|
verifyPrompt,
|
|
436
475
|
verifyTypedEcho
|
|
437
|
-
} from "./chunk-
|
|
476
|
+
} from "./chunk-M7NI3IWE.js";
|
|
438
477
|
import {
|
|
439
478
|
DIRECTORY_RECORD_ID,
|
|
440
479
|
VISIBILITY_RECORD_PREFIX,
|
|
@@ -448,9 +487,9 @@ import {
|
|
|
448
487
|
readUserVisibility,
|
|
449
488
|
saveUserEnvelope,
|
|
450
489
|
visibilityRecordId
|
|
451
|
-
} from "./chunk-
|
|
452
|
-
import "./chunk-
|
|
453
|
-
import "./chunk-
|
|
490
|
+
} from "./chunk-7VCXZDA4.js";
|
|
491
|
+
import "./chunk-SOIQ4MM4.js";
|
|
492
|
+
import "./chunk-4AF3TUMP.js";
|
|
454
493
|
import {
|
|
455
494
|
PolicyEnforcer,
|
|
456
495
|
activeSessionCount,
|
|
@@ -465,7 +504,7 @@ import {
|
|
|
465
504
|
revokeAllSessions,
|
|
466
505
|
revokeSession,
|
|
467
506
|
validateSessionPolicy
|
|
468
|
-
} from "./chunk-
|
|
507
|
+
} from "./chunk-YNIUIERI.js";
|
|
469
508
|
import "./chunk-VKQCVU2Z.js";
|
|
470
509
|
import {
|
|
471
510
|
generateULID,
|
|
@@ -474,17 +513,17 @@ import {
|
|
|
474
513
|
import {
|
|
475
514
|
CollectionInstant,
|
|
476
515
|
VaultInstant
|
|
477
|
-
} from "./chunk-
|
|
516
|
+
} from "./chunk-ISZQJBML.js";
|
|
478
517
|
import {
|
|
479
518
|
diff,
|
|
480
519
|
formatDiff
|
|
481
520
|
} from "./chunk-SVLR4POP.js";
|
|
482
|
-
import "./chunk-
|
|
521
|
+
import "./chunk-QWGU66MP.js";
|
|
483
522
|
import {
|
|
484
523
|
LedgerStore,
|
|
485
524
|
applyPatch,
|
|
486
525
|
computePatch
|
|
487
|
-
} from "./chunk-
|
|
526
|
+
} from "./chunk-ZXABPVM6.js";
|
|
488
527
|
import {
|
|
489
528
|
LEDGER_COLLECTION,
|
|
490
529
|
LEDGER_DELTAS_COLLECTION
|
|
@@ -496,23 +535,23 @@ import {
|
|
|
496
535
|
paddedIndex,
|
|
497
536
|
parseIndex,
|
|
498
537
|
sha256Hex
|
|
499
|
-
} from "./chunk-
|
|
500
|
-
import "./chunk-
|
|
538
|
+
} from "./chunk-CKNGS5MH.js";
|
|
539
|
+
import "./chunk-JCN44NCY.js";
|
|
501
540
|
import "./chunk-HK67PX4J.js";
|
|
502
|
-
import "./chunk-
|
|
541
|
+
import "./chunk-J6UOHJY5.js";
|
|
503
542
|
import {
|
|
504
543
|
buildRecordAad,
|
|
505
544
|
openEnvelopeJson,
|
|
506
545
|
recordAadFor,
|
|
507
546
|
validateSchemaInput,
|
|
508
547
|
validateSchemaOutput
|
|
509
|
-
} from "./chunk-
|
|
548
|
+
} from "./chunk-KJFW62P4.js";
|
|
510
549
|
import {
|
|
511
550
|
buildRecordEnvelope
|
|
512
|
-
} from "./chunk-
|
|
513
|
-
import "./chunk-
|
|
514
|
-
import "./chunk-
|
|
515
|
-
import "./chunk-
|
|
551
|
+
} from "./chunk-SEE332EV.js";
|
|
552
|
+
import "./chunk-6QSQQLSE.js";
|
|
553
|
+
import "./chunk-DE4DH2RZ.js";
|
|
554
|
+
import "./chunk-LQ4ZHOKP.js";
|
|
516
555
|
import "./chunk-LP7BEXCT.js";
|
|
517
556
|
import {
|
|
518
557
|
base64ToBuffer,
|
|
@@ -523,7 +562,7 @@ import {
|
|
|
523
562
|
encrypt,
|
|
524
563
|
encryptBytes,
|
|
525
564
|
encryptDeterministic
|
|
526
|
-
} from "./chunk-
|
|
565
|
+
} from "./chunk-UYB234ZR.js";
|
|
527
566
|
import {
|
|
528
567
|
NOYDB_BACKUP_VERSION,
|
|
529
568
|
NOYDB_ENVELOPE_GENERATION,
|
|
@@ -532,7 +571,7 @@ import {
|
|
|
532
571
|
NOYDB_SYNC_VERSION,
|
|
533
572
|
SealedHandle,
|
|
534
573
|
createStore
|
|
535
|
-
} from "./chunk-
|
|
574
|
+
} from "./chunk-ODVPTDPK.js";
|
|
536
575
|
import {
|
|
537
576
|
AlreadyElevatedError,
|
|
538
577
|
AmendmentForbiddenError,
|
|
@@ -548,6 +587,7 @@ import {
|
|
|
548
587
|
ClassifiedRevealError,
|
|
549
588
|
ClassifiedRotationError,
|
|
550
589
|
ClassifiedVerifyError,
|
|
590
|
+
CollectionNotHydratedError,
|
|
551
591
|
ConflictError,
|
|
552
592
|
CrossJoinSourceUnknownError,
|
|
553
593
|
CrossJoinTooLargeError,
|
|
@@ -608,6 +648,7 @@ import {
|
|
|
608
648
|
OverlayIdMismatchError,
|
|
609
649
|
OverlayNameCollisionError,
|
|
610
650
|
PathEscapeError,
|
|
651
|
+
PeriodChainError,
|
|
611
652
|
PeriodClosedError,
|
|
612
653
|
PermissionDeniedError,
|
|
613
654
|
PersistedIndexCompensationError,
|
|
@@ -618,6 +659,7 @@ import {
|
|
|
618
659
|
PolicyDeniedError,
|
|
619
660
|
PortabilityNotEnabledError,
|
|
620
661
|
PrivilegeEscalationError,
|
|
662
|
+
QueryExtensionMissingError,
|
|
621
663
|
QuiesceTimeoutError,
|
|
622
664
|
ReadOnlyAtInstantError,
|
|
623
665
|
ReadOnlyError,
|
|
@@ -661,6 +703,7 @@ import {
|
|
|
661
703
|
TierWriteRefusedError,
|
|
662
704
|
TiersNotEnabledError,
|
|
663
705
|
TranslatorNotConfiguredError,
|
|
706
|
+
TraversalCycleError,
|
|
664
707
|
USER_ENVELOPE_COLLECTION,
|
|
665
708
|
USER_ENVELOPE_MAX_BYTES,
|
|
666
709
|
UniqueConstraintError,
|
|
@@ -668,6 +711,7 @@ import {
|
|
|
668
711
|
UnknownLookupKeyError,
|
|
669
712
|
UnknownShardError,
|
|
670
713
|
UnknownStoreKindError,
|
|
714
|
+
UnsafePatternError,
|
|
671
715
|
UnsupportedIndexOptionError,
|
|
672
716
|
UnsupportedTierCompositionError,
|
|
673
717
|
UserEnvelopeOversizedError,
|
|
@@ -676,7 +720,129 @@ import {
|
|
|
676
720
|
WrongEchoError,
|
|
677
721
|
WrongPromptError,
|
|
678
722
|
isConflictError
|
|
679
|
-
} from "./chunk-
|
|
723
|
+
} from "./chunk-244VXYPG.js";
|
|
724
|
+
|
|
725
|
+
// src/with-sync/change-broadcast.ts
|
|
726
|
+
function defaultChangeChannel(name) {
|
|
727
|
+
const Bc = globalThis.BroadcastChannel;
|
|
728
|
+
if (typeof Bc !== "function") return void 0;
|
|
729
|
+
const bc = new Bc(name);
|
|
730
|
+
const maybeUnref = bc;
|
|
731
|
+
if (typeof maybeUnref.unref === "function") maybeUnref.unref();
|
|
732
|
+
const listeners = /* @__PURE__ */ new Set();
|
|
733
|
+
bc.onmessage = (e) => {
|
|
734
|
+
for (const l of listeners) l(String(e.data));
|
|
735
|
+
};
|
|
736
|
+
return {
|
|
737
|
+
isOpen: true,
|
|
738
|
+
send(payload) {
|
|
739
|
+
bc.postMessage(payload);
|
|
740
|
+
},
|
|
741
|
+
on(event, listener) {
|
|
742
|
+
if (event === "message") {
|
|
743
|
+
const l = listener;
|
|
744
|
+
listeners.add(l);
|
|
745
|
+
return () => listeners.delete(l);
|
|
746
|
+
}
|
|
747
|
+
return () => {
|
|
748
|
+
};
|
|
749
|
+
},
|
|
750
|
+
close() {
|
|
751
|
+
listeners.clear();
|
|
752
|
+
bc.close();
|
|
753
|
+
}
|
|
754
|
+
};
|
|
755
|
+
}
|
|
756
|
+
function changeChannelName(storeId) {
|
|
757
|
+
return `noydb:change:${storeId}`;
|
|
758
|
+
}
|
|
759
|
+
var ChangeBroadcast = class {
|
|
760
|
+
#host;
|
|
761
|
+
#channel;
|
|
762
|
+
#originId;
|
|
763
|
+
#now;
|
|
764
|
+
#ownsChannel;
|
|
765
|
+
#unsubMsg;
|
|
766
|
+
#started = false;
|
|
767
|
+
#disposed = false;
|
|
768
|
+
constructor(host, channel, opts) {
|
|
769
|
+
this.#host = host;
|
|
770
|
+
this.#channel = channel;
|
|
771
|
+
this.#originId = opts.originId;
|
|
772
|
+
this.#now = opts.now;
|
|
773
|
+
this.#ownsChannel = opts.ownsChannel;
|
|
774
|
+
}
|
|
775
|
+
get originId() {
|
|
776
|
+
return this.#originId;
|
|
777
|
+
}
|
|
778
|
+
start() {
|
|
779
|
+
if (this.#started || this.#disposed) return;
|
|
780
|
+
this.#started = true;
|
|
781
|
+
this.#unsubMsg = this.#channel.on("message", (p) => this.#onMessage(p));
|
|
782
|
+
this.#host.on("change", this.#onLocalChange);
|
|
783
|
+
}
|
|
784
|
+
dispose() {
|
|
785
|
+
if (this.#disposed) return;
|
|
786
|
+
this.#disposed = true;
|
|
787
|
+
this.#host.off("change", this.#onLocalChange);
|
|
788
|
+
this.#unsubMsg?.();
|
|
789
|
+
if (this.#ownsChannel) this.#channel.close();
|
|
790
|
+
}
|
|
791
|
+
/**
|
|
792
|
+
* Echo suppression, first and primary layer: a change this instance produced
|
|
793
|
+
* BY APPLYING a peer's signal is tagged `remote` and is never re-posted. Two
|
|
794
|
+
* instances would otherwise volley one address forever.
|
|
795
|
+
*/
|
|
796
|
+
#onLocalChange = (e) => {
|
|
797
|
+
if (this.#disposed || e.remote === true) return;
|
|
798
|
+
if (!this.#channel.isOpen) return;
|
|
799
|
+
const signal = {
|
|
800
|
+
kind: "noydb:change",
|
|
801
|
+
origin: this.#originId,
|
|
802
|
+
vault: e.vault,
|
|
803
|
+
collection: e.collection,
|
|
804
|
+
id: e.id,
|
|
805
|
+
ts: this.#now()
|
|
806
|
+
};
|
|
807
|
+
this.#channel.send(JSON.stringify(signal));
|
|
808
|
+
};
|
|
809
|
+
#onMessage(payload) {
|
|
810
|
+
if (this.#disposed) return;
|
|
811
|
+
let msg;
|
|
812
|
+
try {
|
|
813
|
+
msg = JSON.parse(payload);
|
|
814
|
+
} catch {
|
|
815
|
+
return;
|
|
816
|
+
}
|
|
817
|
+
if (!isChangeSignal(msg) || msg.origin === this.#originId) return;
|
|
818
|
+
void Promise.resolve(this.#host._applyRemoteSignal(msg.vault, msg.collection, msg.id)).catch((err) => {
|
|
819
|
+
console.warn(`[noy-db] change-signal apply failed for ${msg.collection}/${msg.id}: ` + (err instanceof Error ? err.message : String(err)));
|
|
820
|
+
});
|
|
821
|
+
}
|
|
822
|
+
};
|
|
823
|
+
function enableChangeBroadcast(host, opts = {}) {
|
|
824
|
+
const storeId = opts.storeId ?? host._storeName ?? "default";
|
|
825
|
+
const channel = opts.channel ?? defaultChangeChannel(changeChannelName(storeId));
|
|
826
|
+
if (!channel) return { dispose: () => {
|
|
827
|
+
} };
|
|
828
|
+
const relay = new ChangeBroadcast(host, channel, {
|
|
829
|
+
originId: opts.originId ?? `noydb-${cheapRand()}`,
|
|
830
|
+
now: opts.now ?? (() => Date.now()),
|
|
831
|
+
// Own the channel only when we created it; never close a caller-injected one.
|
|
832
|
+
ownsChannel: opts.channel === void 0
|
|
833
|
+
});
|
|
834
|
+
relay.start();
|
|
835
|
+
return { dispose: () => relay.dispose() };
|
|
836
|
+
}
|
|
837
|
+
function isChangeSignal(x) {
|
|
838
|
+
if (x === null || typeof x !== "object") return false;
|
|
839
|
+
const o = x;
|
|
840
|
+
return o["kind"] === "noydb:change" && typeof o["origin"] === "string" && typeof o["vault"] === "string" && typeof o["collection"] === "string" && typeof o["id"] === "string" && typeof o["ts"] === "number";
|
|
841
|
+
}
|
|
842
|
+
function cheapRand() {
|
|
843
|
+
const g = globalThis;
|
|
844
|
+
return g.crypto?.randomUUID ? g.crypto.randomUUID() : `anon-${Math.random().toString(36).slice(2)}`;
|
|
845
|
+
}
|
|
680
846
|
|
|
681
847
|
// src/with-commit/numbering/descriptor.ts
|
|
682
848
|
function withDeferredNumbering(opts) {
|
|
@@ -694,8 +860,12 @@ function computedVia(cfg) {
|
|
|
694
860
|
const fields = cfg.virtualFields;
|
|
695
861
|
return {
|
|
696
862
|
brand: "computed",
|
|
863
|
+
presentIsSync: true,
|
|
864
|
+
// #1416 — `desc.fn(r)` is declared sync by the computed contract
|
|
697
865
|
posture: VIRTUAL_POSTURE,
|
|
698
866
|
covers: (field) => fields.has(field),
|
|
867
|
+
coveredFields: [...fields.keys()],
|
|
868
|
+
// #1447 — virtual fields live ONLY here, which is why a predicate cannot report them
|
|
699
869
|
present: (record) => {
|
|
700
870
|
let r = record;
|
|
701
871
|
for (const [field, desc] of fields) {
|
|
@@ -710,6 +880,271 @@ function linkComputedVia() {
|
|
|
710
880
|
installViaBinder("computed", (cfg) => computedVia(cfg));
|
|
711
881
|
}
|
|
712
882
|
|
|
883
|
+
// src/via/geo/geohash.ts
|
|
884
|
+
var EARTH_RADIUS_KM = 6371.0088;
|
|
885
|
+
var BASE32 = "0123456789bcdefghjkmnpqrstuvwxyz";
|
|
886
|
+
var MAX_PRECISION = 12;
|
|
887
|
+
var DEG = Math.PI / 180;
|
|
888
|
+
function isGeoPoint(p) {
|
|
889
|
+
if (typeof p !== "object" || p === null) return false;
|
|
890
|
+
const { lat, lng } = p;
|
|
891
|
+
return typeof lat === "number" && Number.isFinite(lat) && lat >= -90 && lat <= 90 && typeof lng === "number" && Number.isFinite(lng) && lng >= -180 && lng <= 180;
|
|
892
|
+
}
|
|
893
|
+
function haversineKm(a, b) {
|
|
894
|
+
const dLat = (b.lat - a.lat) * DEG;
|
|
895
|
+
const dLng = (b.lng - a.lng) * DEG;
|
|
896
|
+
const lat1 = a.lat * DEG;
|
|
897
|
+
const lat2 = b.lat * DEG;
|
|
898
|
+
const h = Math.sin(dLat / 2) ** 2 + Math.cos(lat1) * Math.cos(lat2) * Math.sin(dLng / 2) ** 2;
|
|
899
|
+
return 2 * EARTH_RADIUS_KM * Math.asin(Math.min(1, Math.sqrt(h)));
|
|
900
|
+
}
|
|
901
|
+
function encodeGeohash(point, precision) {
|
|
902
|
+
if (!isGeoPoint(point)) throw new RangeError(`encodeGeohash: not a point: ${JSON.stringify(point)}`);
|
|
903
|
+
const p = clampPrecision(precision);
|
|
904
|
+
let latMin = -90, latMax = 90, lngMin = -180, lngMax = 180;
|
|
905
|
+
let hash = "", bits = 0, ch = 0, evenBit = true;
|
|
906
|
+
while (hash.length < p) {
|
|
907
|
+
if (evenBit) {
|
|
908
|
+
const mid = (lngMin + lngMax) / 2;
|
|
909
|
+
if (point.lng >= mid) {
|
|
910
|
+
ch = (ch << 1) + 1;
|
|
911
|
+
lngMin = mid;
|
|
912
|
+
} else {
|
|
913
|
+
ch <<= 1;
|
|
914
|
+
lngMax = mid;
|
|
915
|
+
}
|
|
916
|
+
} else {
|
|
917
|
+
const mid = (latMin + latMax) / 2;
|
|
918
|
+
if (point.lat >= mid) {
|
|
919
|
+
ch = (ch << 1) + 1;
|
|
920
|
+
latMin = mid;
|
|
921
|
+
} else {
|
|
922
|
+
ch <<= 1;
|
|
923
|
+
latMax = mid;
|
|
924
|
+
}
|
|
925
|
+
}
|
|
926
|
+
evenBit = !evenBit;
|
|
927
|
+
if (++bits === 5) {
|
|
928
|
+
hash += BASE32[ch];
|
|
929
|
+
bits = 0;
|
|
930
|
+
ch = 0;
|
|
931
|
+
}
|
|
932
|
+
}
|
|
933
|
+
return hash;
|
|
934
|
+
}
|
|
935
|
+
function decodeGeohashBox(hash) {
|
|
936
|
+
let latMin = -90, latMax = 90, lngMin = -180, lngMax = 180;
|
|
937
|
+
let evenBit = true;
|
|
938
|
+
for (const c of hash) {
|
|
939
|
+
const idx = BASE32.indexOf(c);
|
|
940
|
+
if (idx < 0) throw new RangeError(`decodeGeohashBox: "${c}" is not a geohash character`);
|
|
941
|
+
for (let n = 4; n >= 0; n--) {
|
|
942
|
+
const bit = idx >> n & 1;
|
|
943
|
+
if (evenBit) {
|
|
944
|
+
const mid = (lngMin + lngMax) / 2;
|
|
945
|
+
if (bit === 1) lngMin = mid;
|
|
946
|
+
else lngMax = mid;
|
|
947
|
+
} else {
|
|
948
|
+
const mid = (latMin + latMax) / 2;
|
|
949
|
+
if (bit === 1) latMin = mid;
|
|
950
|
+
else latMax = mid;
|
|
951
|
+
}
|
|
952
|
+
evenBit = !evenBit;
|
|
953
|
+
}
|
|
954
|
+
}
|
|
955
|
+
return { minLat: latMin, maxLat: latMax, minLng: lngMin, maxLng: lngMax };
|
|
956
|
+
}
|
|
957
|
+
function gridBits(precision) {
|
|
958
|
+
const total = clampPrecision(precision) * 5;
|
|
959
|
+
return { latBits: Math.floor(total / 2), lngBits: Math.ceil(total / 2) };
|
|
960
|
+
}
|
|
961
|
+
function boundingBox(center, radiusKm) {
|
|
962
|
+
if (!isGeoPoint(center)) throw new RangeError(`boundingBox: not a point: ${JSON.stringify(center)}`);
|
|
963
|
+
if (!Number.isFinite(radiusKm) || radiusKm < 0) throw new RangeError(`boundingBox: radiusKm must be a non-negative number, got ${radiusKm}`);
|
|
964
|
+
const eps = 1e-9;
|
|
965
|
+
const angular = radiusKm / EARTH_RADIUS_KM;
|
|
966
|
+
if (angular >= Math.PI) return [{ minLat: -90, maxLat: 90, minLng: -180, maxLng: 180 }];
|
|
967
|
+
const latDelta = angular / DEG + eps;
|
|
968
|
+
const minLat = center.lat - latDelta;
|
|
969
|
+
const maxLat = center.lat + latDelta;
|
|
970
|
+
if (minLat <= -90 || maxLat >= 90) {
|
|
971
|
+
return [{ minLat: Math.max(-90, minLat), maxLat: Math.min(90, maxLat), minLng: -180, maxLng: 180 }];
|
|
972
|
+
}
|
|
973
|
+
const worstLat = Math.max(Math.abs(minLat), Math.abs(maxLat)) * DEG;
|
|
974
|
+
const ratio = Math.sin(angular) / Math.cos(worstLat);
|
|
975
|
+
if (!(ratio < 1)) return [{ minLat, maxLat, minLng: -180, maxLng: 180 }];
|
|
976
|
+
const lngDelta = Math.asin(ratio) / DEG + eps;
|
|
977
|
+
const minLng = center.lng - lngDelta;
|
|
978
|
+
const maxLng = center.lng + lngDelta;
|
|
979
|
+
if (maxLng - minLng >= 360) return [{ minLat, maxLat, minLng: -180, maxLng: 180 }];
|
|
980
|
+
if (minLng < -180) return [{ minLat, maxLat, minLng: -180, maxLng }, { minLat, maxLat, minLng: minLng + 360, maxLng: 180 }];
|
|
981
|
+
if (maxLng > 180) return [{ minLat, maxLat, minLng, maxLng: 180 }, { minLat, maxLat, minLng: -180, maxLng: maxLng - 360 }];
|
|
982
|
+
return [{ minLat, maxLat, minLng, maxLng }];
|
|
983
|
+
}
|
|
984
|
+
function coverSize(boxes, precision) {
|
|
985
|
+
const { latBits, lngBits } = gridBits(precision);
|
|
986
|
+
const latCells = 2 ** latBits;
|
|
987
|
+
const lngCells = 2 ** lngBits;
|
|
988
|
+
let total = 0;
|
|
989
|
+
for (const box of boxes) {
|
|
990
|
+
const i0 = cellIndex(box.minLat, -90, 180, latCells);
|
|
991
|
+
const i1 = cellIndex(box.maxLat, -90, 180, latCells);
|
|
992
|
+
const j0 = cellIndex(box.minLng, -180, 360, lngCells);
|
|
993
|
+
const j1 = cellIndex(box.maxLng, -180, 360, lngCells);
|
|
994
|
+
total += (i1 - i0 + 1) * (j1 - j0 + 1);
|
|
995
|
+
}
|
|
996
|
+
return total;
|
|
997
|
+
}
|
|
998
|
+
function coverPrefixes(boxes, precision) {
|
|
999
|
+
const p = clampPrecision(precision);
|
|
1000
|
+
const { latBits, lngBits } = gridBits(p);
|
|
1001
|
+
const latCells = 2 ** latBits;
|
|
1002
|
+
const lngCells = 2 ** lngBits;
|
|
1003
|
+
const latStep = 180 / latCells;
|
|
1004
|
+
const lngStep = 360 / lngCells;
|
|
1005
|
+
const out = /* @__PURE__ */ new Set();
|
|
1006
|
+
for (const box of boxes) {
|
|
1007
|
+
const i0 = cellIndex(box.minLat, -90, 180, latCells);
|
|
1008
|
+
const i1 = cellIndex(box.maxLat, -90, 180, latCells);
|
|
1009
|
+
const j0 = cellIndex(box.minLng, -180, 360, lngCells);
|
|
1010
|
+
const j1 = cellIndex(box.maxLng, -180, 360, lngCells);
|
|
1011
|
+
for (let i = i0; i <= i1; i++) {
|
|
1012
|
+
const lat = -90 + (i + 0.5) * latStep;
|
|
1013
|
+
for (let j = j0; j <= j1; j++) {
|
|
1014
|
+
const lng = -180 + (j + 0.5) * lngStep;
|
|
1015
|
+
out.add(encodeGeohash({ lat, lng }, p));
|
|
1016
|
+
}
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
1019
|
+
return [...out].sort();
|
|
1020
|
+
}
|
|
1021
|
+
function prefixesForRadius(center, radiusKm, maxPrecision, maxCells) {
|
|
1022
|
+
const boxes = boundingBox(center, radiusKm);
|
|
1023
|
+
const ceiling = Math.max(1, maxCells);
|
|
1024
|
+
for (let p = clampPrecision(maxPrecision); p > 1; p--) {
|
|
1025
|
+
if (coverSize(boxes, p) <= ceiling) return { prefixes: coverPrefixes(boxes, p), precision: p };
|
|
1026
|
+
}
|
|
1027
|
+
return { prefixes: coverPrefixes(boxes, 1), precision: 1 };
|
|
1028
|
+
}
|
|
1029
|
+
function cellIndex(value, origin, span, cells) {
|
|
1030
|
+
const raw = Math.floor((value - origin) / span * cells);
|
|
1031
|
+
return Math.min(cells - 1, Math.max(0, raw));
|
|
1032
|
+
}
|
|
1033
|
+
function clampPrecision(precision) {
|
|
1034
|
+
if (!Number.isInteger(precision) || precision < 1 || precision > MAX_PRECISION) {
|
|
1035
|
+
throw new RangeError(`geo: precision must be an integer in 1..${MAX_PRECISION}, got ${precision}`);
|
|
1036
|
+
}
|
|
1037
|
+
return precision;
|
|
1038
|
+
}
|
|
1039
|
+
|
|
1040
|
+
// src/via/geo/where.ts
|
|
1041
|
+
function geoFieldClause(field, op, value, desc) {
|
|
1042
|
+
if (op !== "near") return { kind: "passthrough", value };
|
|
1043
|
+
if (typeof value !== "object" || value === null) {
|
|
1044
|
+
throw new ValidationError(`where("${field}", 'near', \u2026): operand must be { lat, lng, radiusKm }, got ${JSON.stringify(value)}`);
|
|
1045
|
+
}
|
|
1046
|
+
const { lat, lng, radiusKm } = value;
|
|
1047
|
+
const center = { lat, lng };
|
|
1048
|
+
if (!isGeoPoint(center)) {
|
|
1049
|
+
throw new ValidationError(`where("${field}", 'near', \u2026): lat must be in [-90, 90] and lng in [-180, 180], got ${JSON.stringify({ lat, lng })}`);
|
|
1050
|
+
}
|
|
1051
|
+
if (typeof radiusKm !== "number" || !Number.isFinite(radiusKm) || radiusKm < 0) {
|
|
1052
|
+
throw new ValidationError(`where("${field}", 'near', \u2026): radiusKm must be a non-negative number, got ${JSON.stringify(radiusKm)}`);
|
|
1053
|
+
}
|
|
1054
|
+
const { prefixes, precision } = prefixesForRadius(center, radiusKm, desc.precision, desc.maxPrefixes);
|
|
1055
|
+
return { kind: "near", center, radiusKm, prefixes, precision };
|
|
1056
|
+
}
|
|
1057
|
+
function evaluateGeoClause(actual, op, payload) {
|
|
1058
|
+
if (payload.kind === "passthrough") return evaluateOperator(actual, op, payload.value);
|
|
1059
|
+
if (op !== "near") return false;
|
|
1060
|
+
if (!isGeoPoint(actual)) return false;
|
|
1061
|
+
return haversineKm(actual, payload.center) <= payload.radiusKm;
|
|
1062
|
+
}
|
|
1063
|
+
function geoIndexProbe(op, payload) {
|
|
1064
|
+
if (op !== "near" || payload.kind !== "near") return void 0;
|
|
1065
|
+
if (payload.prefixes.length === 0) return void 0;
|
|
1066
|
+
return { kind: "via-prefixes", prefixes: payload.prefixes };
|
|
1067
|
+
}
|
|
1068
|
+
|
|
1069
|
+
// src/via/geo/binding.ts
|
|
1070
|
+
function geoVia(geoFields) {
|
|
1071
|
+
return {
|
|
1072
|
+
brand: "geo",
|
|
1073
|
+
// A coordinate is ordinary envelope-encrypted content; the ORDERED
|
|
1074
|
+
// posture is what the geohash key earns — a prefix slice is a range
|
|
1075
|
+
// answer, never a plaintext coordinate the store can read.
|
|
1076
|
+
posture: { encryptedAtRest: "envelope", queryable: "ordered", exportable: true, forgettable: true },
|
|
1077
|
+
covers: (field) => field in geoFields,
|
|
1078
|
+
coveredFields: Object.keys(geoFields),
|
|
1079
|
+
// #1447
|
|
1080
|
+
ingest: (record) => {
|
|
1081
|
+
let out = record;
|
|
1082
|
+
for (const [field, desc] of Object.entries(geoFields)) {
|
|
1083
|
+
const value = record[field];
|
|
1084
|
+
if (value === null || value === void 0) continue;
|
|
1085
|
+
if (!isGeoPoint(value)) throw new GeoPointError(field, value);
|
|
1086
|
+
const geohash = encodeGeohash(value, desc.precision);
|
|
1087
|
+
if (out === record) out = { ...record };
|
|
1088
|
+
out[field] = { ...value, geohash };
|
|
1089
|
+
}
|
|
1090
|
+
return out;
|
|
1091
|
+
},
|
|
1092
|
+
// Claims EVERY operator on a covered field, not just `near` — see the
|
|
1093
|
+
// header of `where.ts` for why an unclaimed operator on a field whose
|
|
1094
|
+
// index key is rewritten is a soundness hole rather than a gap.
|
|
1095
|
+
buildClause: (field, op, value) => {
|
|
1096
|
+
const desc = geoFields[field];
|
|
1097
|
+
if (!desc) return void 0;
|
|
1098
|
+
return geoFieldClause(field, op, value, desc);
|
|
1099
|
+
},
|
|
1100
|
+
evaluateClause: (actual, op, payload) => evaluateGeoClause(actual, op, payload),
|
|
1101
|
+
indexProbe: (op, payload) => geoIndexProbe(op, payload),
|
|
1102
|
+
canonicalizeIndexKey: (field, rawValue) => {
|
|
1103
|
+
const desc = geoFields[field];
|
|
1104
|
+
if (!desc || !isGeoPoint(rawValue)) return void 0;
|
|
1105
|
+
return encodeGeohash(rawValue, desc.precision);
|
|
1106
|
+
},
|
|
1107
|
+
describeFragment: () => ({
|
|
1108
|
+
geo: Object.fromEntries(
|
|
1109
|
+
Object.entries(geoFields).map(([field, d]) => [field, { precision: d.precision, maxPrefixes: d.maxPrefixes }])
|
|
1110
|
+
)
|
|
1111
|
+
})
|
|
1112
|
+
};
|
|
1113
|
+
}
|
|
1114
|
+
function linkGeoVia() {
|
|
1115
|
+
installViaBinder("geo", (cfg) => geoVia(cfg.geoFields));
|
|
1116
|
+
}
|
|
1117
|
+
|
|
1118
|
+
// src/via/geo/descriptor.ts
|
|
1119
|
+
var GeoPointError = class extends NoydbError {
|
|
1120
|
+
constructor(field, value) {
|
|
1121
|
+
super(
|
|
1122
|
+
"GEO_POINT",
|
|
1123
|
+
`geo: field "${field}" expects { lat, lng } with lat in [-90, 90] and lng in [-180, 180], got ${JSON.stringify(value)}`
|
|
1124
|
+
);
|
|
1125
|
+
this.field = field;
|
|
1126
|
+
this.value = value;
|
|
1127
|
+
this.name = "GeoPointError";
|
|
1128
|
+
}
|
|
1129
|
+
field;
|
|
1130
|
+
value;
|
|
1131
|
+
};
|
|
1132
|
+
function geo(options = {}) {
|
|
1133
|
+
linkGeoVia();
|
|
1134
|
+
const precision = options.precision ?? 9;
|
|
1135
|
+
if (!Number.isInteger(precision) || precision < 1 || precision > MAX_PRECISION) {
|
|
1136
|
+
throw new TypeError(`geo: precision must be an integer in 1..${MAX_PRECISION}, got ${String(precision)}`);
|
|
1137
|
+
}
|
|
1138
|
+
const maxPrefixes = options.maxPrefixes ?? 32;
|
|
1139
|
+
if (!Number.isInteger(maxPrefixes) || maxPrefixes < 1) {
|
|
1140
|
+
throw new TypeError(`geo: maxPrefixes must be a positive integer, got ${String(maxPrefixes)}`);
|
|
1141
|
+
}
|
|
1142
|
+
return { _viaBrand: "geo", precision, maxPrefixes };
|
|
1143
|
+
}
|
|
1144
|
+
function isGeoDescriptor(x) {
|
|
1145
|
+
return typeof x === "object" && x !== null && x._viaBrand === "geo";
|
|
1146
|
+
}
|
|
1147
|
+
|
|
713
1148
|
// src/via/computed/descriptor.ts
|
|
714
1149
|
function computed(fn, opts) {
|
|
715
1150
|
linkComputedVia();
|
|
@@ -932,6 +1367,8 @@ function lookupVia(cfg) {
|
|
|
932
1367
|
posture: { encryptedAtRest: "envelope", queryable: "full", exportable: true, forgettable: false },
|
|
933
1368
|
reservedPrefixes: ["_dict_", "_lookup_"],
|
|
934
1369
|
covers: (field) => field in cfg.lookupFields,
|
|
1370
|
+
coveredFields: Object.keys(cfg.lookupFields),
|
|
1371
|
+
// #1447
|
|
935
1372
|
ingest: (record) => runLookupIngest(record, cfg),
|
|
936
1373
|
enforceWrite: (record) => runLookupEnforceWrite(record, cfg),
|
|
937
1374
|
present: async (record, ctx) => runLookupPresent(record, ctx, cfg),
|
|
@@ -1049,7 +1486,342 @@ async function credentialStatus(adapter, vault, keyring, adapterId) {
|
|
|
1049
1486
|
const expired = credential.expiresAt ? Date.now() > new Date(credential.expiresAt).getTime() : false;
|
|
1050
1487
|
return { exists: true, expired };
|
|
1051
1488
|
}
|
|
1489
|
+
|
|
1490
|
+
// src/with-store/partitioned/index.ts
|
|
1491
|
+
var PARTITION_REGISTRY_COLLECTION = "_partition_sets";
|
|
1492
|
+
var defaultPartitionNamer = (name, partition) => `${name}@${partition}`;
|
|
1493
|
+
function partitioned(vault, spec) {
|
|
1494
|
+
return new PartitionedCollection(vault, spec);
|
|
1495
|
+
}
|
|
1496
|
+
var PartitionedCollection = class {
|
|
1497
|
+
name;
|
|
1498
|
+
key;
|
|
1499
|
+
vault;
|
|
1500
|
+
namer;
|
|
1501
|
+
collectionOptions;
|
|
1502
|
+
declared;
|
|
1503
|
+
/**
|
|
1504
|
+
* Session cache of the REGISTRY's partition list — deliberately not of the
|
|
1505
|
+
* merged set. The two are different questions and conflating them cost a
|
|
1506
|
+
* red test: `ensurePartition` must persist a partition the caller DECLARED
|
|
1507
|
+
* but never wrote, and a cache of the merged set makes every declared value
|
|
1508
|
+
* look already-known, so the registry stays empty and a later session that
|
|
1509
|
+
* declares nothing enumerates nothing.
|
|
1510
|
+
*/
|
|
1511
|
+
stored = null;
|
|
1512
|
+
constructor(vault, spec) {
|
|
1513
|
+
this.vault = vault;
|
|
1514
|
+
this.name = spec.name;
|
|
1515
|
+
this.key = spec.key;
|
|
1516
|
+
this.namer = spec.namer ?? defaultPartitionNamer;
|
|
1517
|
+
this.collectionOptions = spec.collectionOptions;
|
|
1518
|
+
this.declared = [...spec.partitions ?? []];
|
|
1519
|
+
}
|
|
1520
|
+
/** The member collection name for a partition value. */
|
|
1521
|
+
collectionNameOf(partition) {
|
|
1522
|
+
return this.namer(this.name, partition);
|
|
1523
|
+
}
|
|
1524
|
+
/** The member `Collection` for one partition. */
|
|
1525
|
+
partition(value) {
|
|
1526
|
+
return this.vault.collection(
|
|
1527
|
+
this.collectionNameOf(value),
|
|
1528
|
+
this.collectionOptions
|
|
1529
|
+
);
|
|
1530
|
+
}
|
|
1531
|
+
/**
|
|
1532
|
+
* The declared partition set, in declaration order.
|
|
1533
|
+
*
|
|
1534
|
+
* ⭐ **This is the "cheap enumeration" half of #1342, and cheap means a
|
|
1535
|
+
* measured thing.** `vault.collections()` is `adapter.loadAll(vault)` — the
|
|
1536
|
+
* whole vault snapshot, every collection, every envelope — so enumerating
|
|
1537
|
+
* twelve quarters cost a full load before this existed. Here it is ONE
|
|
1538
|
+
* record read out of {@link PARTITION_REGISTRY_COLLECTION}, and zero reads
|
|
1539
|
+
* once the session has resolved it.
|
|
1540
|
+
* `__tests__/partitioned-collection.test.ts` asserts the `loadAll` count is
|
|
1541
|
+
* zero rather than trusting the sentence.
|
|
1542
|
+
*/
|
|
1543
|
+
async partitions() {
|
|
1544
|
+
const stored = await this.loadStored();
|
|
1545
|
+
const merged = [...this.declared];
|
|
1546
|
+
for (const p of stored) if (!merged.includes(p)) merged.push(p);
|
|
1547
|
+
return merged;
|
|
1548
|
+
}
|
|
1549
|
+
/**
|
|
1550
|
+
* Declare a partition, persisting it so a later session enumerates it
|
|
1551
|
+
* without the caller re-declaring. Idempotent, and keyed on what the
|
|
1552
|
+
* REGISTRY holds rather than on what this handle declared.
|
|
1553
|
+
*/
|
|
1554
|
+
async ensurePartition(value) {
|
|
1555
|
+
const stored = await this.loadStored();
|
|
1556
|
+
if (stored.includes(value)) return;
|
|
1557
|
+
stored.push(value);
|
|
1558
|
+
await this.registry().put(this.name, { id: this.name, partitions: [...stored] });
|
|
1559
|
+
}
|
|
1560
|
+
async loadStored() {
|
|
1561
|
+
if (this.stored === null) {
|
|
1562
|
+
this.stored = [...(await this.registry().get(this.name))?.partitions ?? []];
|
|
1563
|
+
}
|
|
1564
|
+
return this.stored;
|
|
1565
|
+
}
|
|
1566
|
+
/**
|
|
1567
|
+
* Write a record into the partition its key names, declaring that partition
|
|
1568
|
+
* if it is new.
|
|
1569
|
+
*
|
|
1570
|
+
* Throws when `record[key]` is not a string — a partition value names a
|
|
1571
|
+
* collection, and routing a record to a partition derived by coercion is
|
|
1572
|
+
* how a record ends up somewhere no query will look for it.
|
|
1573
|
+
*/
|
|
1574
|
+
async put(id, record) {
|
|
1575
|
+
const value = record[this.key];
|
|
1576
|
+
if (typeof value !== "string" || value === "") {
|
|
1577
|
+
throw new PartitionKeyError(this.name, this.key, value);
|
|
1578
|
+
}
|
|
1579
|
+
await this.ensurePartition(value);
|
|
1580
|
+
await this.partition(value).put(id, record);
|
|
1581
|
+
}
|
|
1582
|
+
/** A union query across the member collections, pruned by the predicate. */
|
|
1583
|
+
query() {
|
|
1584
|
+
return new PartitionedQuery(this, [], [], void 0, 0);
|
|
1585
|
+
}
|
|
1586
|
+
/**
|
|
1587
|
+
* A union scan across the member collections, pruned by the predicate.
|
|
1588
|
+
* Pages are decrypted, so an excluded partition is decryption never paid.
|
|
1589
|
+
*/
|
|
1590
|
+
scan(opts = {}) {
|
|
1591
|
+
return new PartitionedScan(this, [], opts.pageSize ?? 100);
|
|
1592
|
+
}
|
|
1593
|
+
/** @internal — the normalizer for clause shapes, and the union's legs. */
|
|
1594
|
+
_registryName() {
|
|
1595
|
+
return PARTITION_REGISTRY_COLLECTION;
|
|
1596
|
+
}
|
|
1597
|
+
registry() {
|
|
1598
|
+
return this.vault.collection(
|
|
1599
|
+
PARTITION_REGISTRY_COLLECTION
|
|
1600
|
+
);
|
|
1601
|
+
}
|
|
1602
|
+
};
|
|
1603
|
+
var PartitionKeyError = class extends Error {
|
|
1604
|
+
constructor(collection, key, value) {
|
|
1605
|
+
super(
|
|
1606
|
+
`[noy-db] partitioned("${collection}"): record.${key} must be a non-empty string naming its partition, got ${typeof value === "string" ? '""' : String(value)}. A partition value names a collection; it is never coerced.`
|
|
1607
|
+
);
|
|
1608
|
+
this.name = "PartitionKeyError";
|
|
1609
|
+
}
|
|
1610
|
+
};
|
|
1611
|
+
function replay(builder, steps) {
|
|
1612
|
+
let out = builder;
|
|
1613
|
+
for (const step of steps) {
|
|
1614
|
+
out = step.kind === "where" ? out.where(step.field, step.op, step.value) : out.filter(step.fn);
|
|
1615
|
+
}
|
|
1616
|
+
return out;
|
|
1617
|
+
}
|
|
1618
|
+
function normalizedClauses(col, declared, steps) {
|
|
1619
|
+
if (declared.length === 0) return [];
|
|
1620
|
+
const probe = replay(col.partition(declared[0]).query(), steps);
|
|
1621
|
+
return probe._plan().clauses;
|
|
1622
|
+
}
|
|
1623
|
+
var PartitionedQuery = class _PartitionedQuery {
|
|
1624
|
+
constructor(col, steps, orderBys, limitN, offsetN) {
|
|
1625
|
+
this.col = col;
|
|
1626
|
+
this.steps = steps;
|
|
1627
|
+
this.orderBys = orderBys;
|
|
1628
|
+
this.limitN = limitN;
|
|
1629
|
+
this.offsetN = offsetN;
|
|
1630
|
+
}
|
|
1631
|
+
col;
|
|
1632
|
+
steps;
|
|
1633
|
+
orderBys;
|
|
1634
|
+
limitN;
|
|
1635
|
+
offsetN;
|
|
1636
|
+
with(patch) {
|
|
1637
|
+
return new _PartitionedQuery(
|
|
1638
|
+
this.col,
|
|
1639
|
+
patch.steps ?? this.steps,
|
|
1640
|
+
patch.orderBys ?? this.orderBys,
|
|
1641
|
+
"limitN" in patch ? patch.limitN : this.limitN,
|
|
1642
|
+
patch.offsetN ?? this.offsetN
|
|
1643
|
+
);
|
|
1644
|
+
}
|
|
1645
|
+
where(field, op, value) {
|
|
1646
|
+
return this.with({ steps: [...this.steps, { kind: "where", field, op, value }] });
|
|
1647
|
+
}
|
|
1648
|
+
filter(fn) {
|
|
1649
|
+
return this.with({ steps: [...this.steps, { kind: "filter", fn }] });
|
|
1650
|
+
}
|
|
1651
|
+
orderBy(field, direction = "asc") {
|
|
1652
|
+
return this.with({ orderBys: [...this.orderBys, { field, direction }] });
|
|
1653
|
+
}
|
|
1654
|
+
limit(n) {
|
|
1655
|
+
return this.with({ limitN: n });
|
|
1656
|
+
}
|
|
1657
|
+
offset(n) {
|
|
1658
|
+
return this.with({ offsetN: n });
|
|
1659
|
+
}
|
|
1660
|
+
/** The pruning decision for this query, and the set it was taken against. */
|
|
1661
|
+
async scope() {
|
|
1662
|
+
const declared = await this.col.partitions();
|
|
1663
|
+
const clauses = normalizedClauses(this.col, declared, this.steps);
|
|
1664
|
+
return { declared, scope: resolvePartitionScope(clauses, this.col.key, declared) };
|
|
1665
|
+
}
|
|
1666
|
+
/**
|
|
1667
|
+
* The matched rows, unordered and unpaged — the set every reduce-shaped
|
|
1668
|
+
* terminal reports over, matching `Query.count()`'s rule that orderBy /
|
|
1669
|
+
* limit / offset describe a page and a reduction is not paginated.
|
|
1670
|
+
*/
|
|
1671
|
+
async matched() {
|
|
1672
|
+
const { declared, scope } = await this.scope();
|
|
1673
|
+
const rows = [];
|
|
1674
|
+
for (const p of partitionsInScope(scope, declared)) {
|
|
1675
|
+
const leg = replay(this.col.partition(p).query(), this.steps);
|
|
1676
|
+
rows.push(...leg.toArray());
|
|
1677
|
+
}
|
|
1678
|
+
return rows;
|
|
1679
|
+
}
|
|
1680
|
+
/** The union, sorted then paged. */
|
|
1681
|
+
async all() {
|
|
1682
|
+
let rows = await this.matched();
|
|
1683
|
+
if (this.orderBys.length > 0) rows = sortRecords(rows, this.orderBys);
|
|
1684
|
+
if (this.offsetN > 0) rows = rows.slice(this.offsetN);
|
|
1685
|
+
if (this.limitN !== void 0) rows = rows.slice(0, this.limitN);
|
|
1686
|
+
return rows;
|
|
1687
|
+
}
|
|
1688
|
+
async first() {
|
|
1689
|
+
return (await this.all())[0] ?? null;
|
|
1690
|
+
}
|
|
1691
|
+
async count() {
|
|
1692
|
+
return (await this.matched()).length;
|
|
1693
|
+
}
|
|
1694
|
+
async aggregate(spec) {
|
|
1695
|
+
return reduceRecords(await this.matched(), spec);
|
|
1696
|
+
}
|
|
1697
|
+
/**
|
|
1698
|
+
* The plan, with the partition decision as its first line:
|
|
1699
|
+
*
|
|
1700
|
+
* ```
|
|
1701
|
+
* partitions partitions: 1 of 12 scanned [partitions:pruned] -- key "period"; FY2026-Q1
|
|
1702
|
+
* source snapshot (no indexes) [source] rows=500
|
|
1703
|
+
* where period == "FY2026-Q1" [scan] rows=500
|
|
1704
|
+
* ```
|
|
1705
|
+
*
|
|
1706
|
+
* ⭐ The dispatch label is decided by {@link resolvePartitionScope} — the
|
|
1707
|
+
* SAME call the executor makes, not a mirror of it. `explain.ts`'s header
|
|
1708
|
+
* warns that its index dispatch mirrors `candidateRecords`; #1375 deleted
|
|
1709
|
+
* one such mirror, and a partition dispatch would have been a third site.
|
|
1710
|
+
*
|
|
1711
|
+
* The nodes after the partition line are the FIRST in-scope member's own
|
|
1712
|
+
* explanation. Every member runs the same plan over the same shape, so one
|
|
1713
|
+
* leg's nodes describe them all; the partition line is what says how many
|
|
1714
|
+
* legs there are.
|
|
1715
|
+
*/
|
|
1716
|
+
async explain() {
|
|
1717
|
+
const { declared, scope } = await this.scope();
|
|
1718
|
+
const inScope = partitionsInScope(scope, declared);
|
|
1719
|
+
const pruned = scope !== ALL_PARTITIONS && inScope.length < declared.length;
|
|
1720
|
+
const notes = [`key "${this.col.key}"`];
|
|
1721
|
+
notes.push(
|
|
1722
|
+
inScope.length === 0 ? "no partition admits this predicate \u2014 nothing is read" : inScope.join(", ")
|
|
1723
|
+
);
|
|
1724
|
+
if (!pruned && declared.length > 0) {
|
|
1725
|
+
notes.push("predicate proves no narrowing \u2014 every partition is read");
|
|
1726
|
+
}
|
|
1727
|
+
const head = {
|
|
1728
|
+
op: "partitions",
|
|
1729
|
+
dispatch: pruned ? "partitions:pruned" : "partitions:all",
|
|
1730
|
+
detail: describePartitionScope(scope, declared),
|
|
1731
|
+
estimatedRows: void 0,
|
|
1732
|
+
notes,
|
|
1733
|
+
children: []
|
|
1734
|
+
};
|
|
1735
|
+
const legNodes = inScope.length === 0 ? [] : replay(this.col.partition(inScope[0]).query(), this.steps).explain().nodes;
|
|
1736
|
+
const nodes = [head, ...legNodes];
|
|
1737
|
+
return { nodes, caps: [], reducerRewrite: [], text: renderExplainText(nodes) };
|
|
1738
|
+
}
|
|
1739
|
+
};
|
|
1740
|
+
var PartitionedScan = class _PartitionedScan {
|
|
1741
|
+
constructor(col, steps, pageSize) {
|
|
1742
|
+
this.col = col;
|
|
1743
|
+
this.steps = steps;
|
|
1744
|
+
this.pageSize = pageSize;
|
|
1745
|
+
}
|
|
1746
|
+
col;
|
|
1747
|
+
steps;
|
|
1748
|
+
pageSize;
|
|
1749
|
+
where(field, op, value) {
|
|
1750
|
+
return new _PartitionedScan(
|
|
1751
|
+
this.col,
|
|
1752
|
+
[...this.steps, { kind: "where", field, op, value }],
|
|
1753
|
+
this.pageSize
|
|
1754
|
+
);
|
|
1755
|
+
}
|
|
1756
|
+
filter(fn) {
|
|
1757
|
+
return new _PartitionedScan(this.col, [...this.steps, { kind: "filter", fn }], this.pageSize);
|
|
1758
|
+
}
|
|
1759
|
+
/** The pruning decision for this scan, and the set it was taken against. */
|
|
1760
|
+
async scope() {
|
|
1761
|
+
const declared = await this.col.partitions();
|
|
1762
|
+
const clauses = normalizedClauses(this.col, declared, this.steps);
|
|
1763
|
+
return { declared, scope: resolvePartitionScope(clauses, this.col.key, declared) };
|
|
1764
|
+
}
|
|
1765
|
+
/**
|
|
1766
|
+
* The union as a single {@link ScanBuilder} — so `.aggregate()`,
|
|
1767
|
+
* `.groupBy()` and `for await` come from the streaming machinery that
|
|
1768
|
+
* already exists, at its existing O(reducers) memory bound, rather than
|
|
1769
|
+
* from a second implementation of it.
|
|
1770
|
+
*/
|
|
1771
|
+
async builder() {
|
|
1772
|
+
const { declared, scope } = await this.scope();
|
|
1773
|
+
const members = partitionsInScope(scope, declared).map((p) => this.col.partition(p));
|
|
1774
|
+
return replay(
|
|
1775
|
+
new ScanBuilder(unionPageProvider(members), this.pageSize),
|
|
1776
|
+
this.steps
|
|
1777
|
+
);
|
|
1778
|
+
}
|
|
1779
|
+
async *[Symbol.asyncIterator]() {
|
|
1780
|
+
yield* await this.builder();
|
|
1781
|
+
}
|
|
1782
|
+
async aggregate(spec) {
|
|
1783
|
+
return (await this.builder()).aggregate(spec);
|
|
1784
|
+
}
|
|
1785
|
+
/**
|
|
1786
|
+
* **ASYNC here, unlike `Query.toArray()` (#1413).** Same method name, a
|
|
1787
|
+
* different contract, because the surface underneath differs: this one
|
|
1788
|
+
* genuinely fetches across every partition leg, so it genuinely awaits. `Query`'s terminal reads an
|
|
1789
|
+
* already-decrypted in-memory cache and returns `T[]` synchronously.
|
|
1790
|
+
*/
|
|
1791
|
+
async toArray() {
|
|
1792
|
+
const out = [];
|
|
1793
|
+
for await (const record of this) out.push(record);
|
|
1794
|
+
return out;
|
|
1795
|
+
}
|
|
1796
|
+
};
|
|
1797
|
+
function unionPageProvider(members) {
|
|
1798
|
+
return {
|
|
1799
|
+
async listPage(opts) {
|
|
1800
|
+
let index = 0;
|
|
1801
|
+
let inner;
|
|
1802
|
+
if (opts.cursor !== void 0) {
|
|
1803
|
+
const at = opts.cursor.indexOf("|");
|
|
1804
|
+
index = Number.parseInt(opts.cursor.slice(0, at), 10);
|
|
1805
|
+
const rest = opts.cursor.slice(at + 1);
|
|
1806
|
+
inner = rest === "" ? void 0 : rest;
|
|
1807
|
+
}
|
|
1808
|
+
while (index < members.length) {
|
|
1809
|
+
const page = await members[index].listPage({ ...inner !== void 0 ? { cursor: inner } : {}, ...opts.limit !== void 0 ? { limit: opts.limit } : {} });
|
|
1810
|
+
if (page.nextCursor !== null) {
|
|
1811
|
+
return { items: page.items, nextCursor: `${index}|${page.nextCursor}` };
|
|
1812
|
+
}
|
|
1813
|
+
index += 1;
|
|
1814
|
+
inner = void 0;
|
|
1815
|
+
if (page.items.length > 0) {
|
|
1816
|
+
return { items: page.items, nextCursor: index < members.length ? `${index}|` : null };
|
|
1817
|
+
}
|
|
1818
|
+
}
|
|
1819
|
+
return { items: [], nextCursor: null };
|
|
1820
|
+
}
|
|
1821
|
+
};
|
|
1822
|
+
}
|
|
1052
1823
|
export {
|
|
1824
|
+
ALL_PARTITIONS,
|
|
1053
1825
|
AlreadyElevatedError,
|
|
1054
1826
|
AmendmentForbiddenError,
|
|
1055
1827
|
AttestationError,
|
|
@@ -1069,6 +1841,7 @@ export {
|
|
|
1069
1841
|
COVER_FIELDS,
|
|
1070
1842
|
COVER_RECORD_ID,
|
|
1071
1843
|
CargoNotEnabledError,
|
|
1844
|
+
ChangeBroadcast,
|
|
1072
1845
|
ClassifiedConfigError,
|
|
1073
1846
|
ClassifiedNeverStoredError,
|
|
1074
1847
|
ClassifiedNotEnabledError,
|
|
@@ -1080,6 +1853,7 @@ export {
|
|
|
1080
1853
|
CollectionFrame,
|
|
1081
1854
|
CollectionIndexes,
|
|
1082
1855
|
CollectionInstant,
|
|
1856
|
+
CollectionNotHydratedError,
|
|
1083
1857
|
ComputedFieldError,
|
|
1084
1858
|
ConflictError,
|
|
1085
1859
|
CrossJoinSourceUnknownError,
|
|
@@ -1092,6 +1866,7 @@ export {
|
|
|
1092
1866
|
DEFAULT_ECHO_MIN_WORD_LENGTH,
|
|
1093
1867
|
DEFAULT_ECHO_PROMPT_MIN_WORDS,
|
|
1094
1868
|
DEFAULT_FRESHNESS_MS,
|
|
1869
|
+
DEFAULT_INDEX_MIN_VECTORS,
|
|
1095
1870
|
DEFAULT_JOIN_MAX_ROWS,
|
|
1096
1871
|
DICT_COLLECTION_PREFIX,
|
|
1097
1872
|
DIRECTORY_RECORD_ID,
|
|
@@ -1110,6 +1885,7 @@ export {
|
|
|
1110
1885
|
DirectoryDisabledError,
|
|
1111
1886
|
DuplicateBehaviorNameError,
|
|
1112
1887
|
DuplicateStoreKindError,
|
|
1888
|
+
EARTH_RADIUS_KM,
|
|
1113
1889
|
ELEVATION_AUDIT_COLLECTION,
|
|
1114
1890
|
EchoCeremonyRequiredError,
|
|
1115
1891
|
ElevatedHandle,
|
|
@@ -1122,6 +1898,8 @@ export {
|
|
|
1122
1898
|
FieldNotQueryableError,
|
|
1123
1899
|
FilenameSanitizationError,
|
|
1124
1900
|
ForgetStrategyNotConfiguredError,
|
|
1901
|
+
MAX_PRECISION as GEO_MAX_PRECISION,
|
|
1902
|
+
GeoPointError,
|
|
1125
1903
|
GroupCardinalityError,
|
|
1126
1904
|
INDEXED_STORE_POLICY,
|
|
1127
1905
|
IllegalTransitionError,
|
|
@@ -1183,12 +1961,18 @@ export {
|
|
|
1183
1961
|
OverlayCollectionUnavailableError,
|
|
1184
1962
|
OverlayIdMismatchError,
|
|
1185
1963
|
OverlayNameCollisionError,
|
|
1964
|
+
PARTITION_REGISTRY_COLLECTION,
|
|
1186
1965
|
PERIODS_COLLECTION,
|
|
1187
1966
|
PERSONAL_POLICY,
|
|
1188
1967
|
POD_SIG_ALG,
|
|
1189
1968
|
POD_STORE_POLICY,
|
|
1190
1969
|
POLICY_RECORD_ID,
|
|
1970
|
+
PartitionKeyError,
|
|
1971
|
+
PartitionedCollection,
|
|
1972
|
+
PartitionedQuery,
|
|
1973
|
+
PartitionedScan,
|
|
1191
1974
|
PathEscapeError,
|
|
1975
|
+
PeriodChainError,
|
|
1192
1976
|
PeriodClosedError,
|
|
1193
1977
|
PermissionDeniedError,
|
|
1194
1978
|
PersistedIndexCompensationError,
|
|
@@ -1202,6 +1986,7 @@ export {
|
|
|
1202
1986
|
PresenceHandle,
|
|
1203
1987
|
PrivilegeEscalationError,
|
|
1204
1988
|
Query,
|
|
1989
|
+
QueryExtensionMissingError,
|
|
1205
1990
|
QuickUnlockStore,
|
|
1206
1991
|
QuiesceTimeoutError,
|
|
1207
1992
|
ReadOnlyAtInstantError,
|
|
@@ -1226,7 +2011,7 @@ export {
|
|
|
1226
2011
|
STATE_VAULT_NAME,
|
|
1227
2012
|
STRICT_POLICY,
|
|
1228
2013
|
SYNC_CREDENTIALS_COLLECTION,
|
|
1229
|
-
ScanBuilder,
|
|
2014
|
+
ScanBuilder2 as ScanBuilder,
|
|
1230
2015
|
SchemaFenceError,
|
|
1231
2016
|
SchemaLockedError,
|
|
1232
2017
|
SchemaUpdateError,
|
|
@@ -1258,6 +2043,7 @@ export {
|
|
|
1258
2043
|
TierWriteRefusedError,
|
|
1259
2044
|
TiersNotEnabledError,
|
|
1260
2045
|
TranslatorNotConfiguredError,
|
|
2046
|
+
TraversalCycleError,
|
|
1261
2047
|
TxCollection,
|
|
1262
2048
|
TxContext,
|
|
1263
2049
|
TxVault,
|
|
@@ -1268,6 +2054,7 @@ export {
|
|
|
1268
2054
|
UnknownLookupKeyError,
|
|
1269
2055
|
UnknownShardError,
|
|
1270
2056
|
UnknownStoreKindError,
|
|
2057
|
+
UnsafePatternError,
|
|
1271
2058
|
UnsupportedIndexOptionError,
|
|
1272
2059
|
UnsupportedTierCompositionError,
|
|
1273
2060
|
UserApi,
|
|
@@ -1305,6 +2092,7 @@ export {
|
|
|
1305
2092
|
buildRecipientKeyringFile,
|
|
1306
2093
|
burnPaperRecoveryEntry,
|
|
1307
2094
|
canonicalJson,
|
|
2095
|
+
changeChannelName,
|
|
1308
2096
|
checkGate,
|
|
1309
2097
|
classified,
|
|
1310
2098
|
clearDevUnlock,
|
|
@@ -1320,9 +2108,12 @@ export {
|
|
|
1320
2108
|
createSession,
|
|
1321
2109
|
createStore,
|
|
1322
2110
|
credentialStatus,
|
|
2111
|
+
decodeGeohashBox,
|
|
1323
2112
|
decryptBytes,
|
|
1324
2113
|
decryptDeterministic,
|
|
1325
2114
|
decryptExtractedPartition,
|
|
2115
|
+
defaultChangeChannel,
|
|
2116
|
+
defaultPartitionNamer,
|
|
1326
2117
|
deleteCredential,
|
|
1327
2118
|
deleteIntent,
|
|
1328
2119
|
deleteUserEnvelope,
|
|
@@ -1343,7 +2134,9 @@ export {
|
|
|
1343
2134
|
dictKey,
|
|
1344
2135
|
diff,
|
|
1345
2136
|
diffVault,
|
|
2137
|
+
enableChangeBroadcast,
|
|
1346
2138
|
enableDevUnlock,
|
|
2139
|
+
encodeGeohash,
|
|
1347
2140
|
encryptBytes,
|
|
1348
2141
|
encryptDeterministic,
|
|
1349
2142
|
enforceScript,
|
|
@@ -1360,18 +2153,26 @@ export {
|
|
|
1360
2153
|
evaluateImportCapability,
|
|
1361
2154
|
exactMath,
|
|
1362
2155
|
executePlan,
|
|
2156
|
+
explainPlan,
|
|
1363
2157
|
exportAccessibleData,
|
|
1364
2158
|
findAuthenticator,
|
|
1365
2159
|
followRedirects,
|
|
1366
2160
|
formatDiff,
|
|
1367
2161
|
fuseRetrieval,
|
|
1368
2162
|
generateULID,
|
|
2163
|
+
geo,
|
|
2164
|
+
boundingBox as geoBoundingBox,
|
|
2165
|
+
coverPrefixes as geoCoverPrefixes,
|
|
2166
|
+
coverSize as geoCoverSize,
|
|
2167
|
+
gridBits as geoGridBits,
|
|
2168
|
+
prefixesForRadius as geoPrefixesForRadius,
|
|
1369
2169
|
getCredential,
|
|
1370
2170
|
getIntent,
|
|
1371
2171
|
hasExportCapability,
|
|
1372
2172
|
hasImportCapability,
|
|
1373
2173
|
hasNoydbPodMagic,
|
|
1374
2174
|
hashEntry,
|
|
2175
|
+
haversineKm,
|
|
1375
2176
|
i18nText,
|
|
1376
2177
|
immutableGuard,
|
|
1377
2178
|
importExternalObjects,
|
|
@@ -1386,6 +2187,8 @@ export {
|
|
|
1386
2187
|
isDictCollectionName,
|
|
1387
2188
|
isDictKeyDescriptor,
|
|
1388
2189
|
isDiscriminant,
|
|
2190
|
+
isGeoDescriptor,
|
|
2191
|
+
isGeoPoint,
|
|
1389
2192
|
isI18nTextDescriptor,
|
|
1390
2193
|
isLinkCollectionName,
|
|
1391
2194
|
isMagicLinkGrantExpired,
|
|
@@ -1398,6 +2201,7 @@ export {
|
|
|
1398
2201
|
isStaticDictDescriptor,
|
|
1399
2202
|
isULID,
|
|
1400
2203
|
isViaFieldSpec,
|
|
2204
|
+
isViaPrefixProbe,
|
|
1401
2205
|
isZodSchema,
|
|
1402
2206
|
recoverSecret as keyringRecoverSecret,
|
|
1403
2207
|
rotateSecret as keyringRotateSecret,
|
|
@@ -1435,6 +2239,7 @@ export {
|
|
|
1435
2239
|
parseBytes,
|
|
1436
2240
|
parseIndex,
|
|
1437
2241
|
parseRsaOaepTlv,
|
|
2242
|
+
partitioned,
|
|
1438
2243
|
persistDirectoryConfig,
|
|
1439
2244
|
persistSchemaIfNeeded,
|
|
1440
2245
|
persistUserVisibility,
|
|
@@ -1460,6 +2265,7 @@ export {
|
|
|
1460
2265
|
resolveCrdtSnapshot,
|
|
1461
2266
|
resolveEchoReveal,
|
|
1462
2267
|
resolveI18nText,
|
|
2268
|
+
resolvePartitionScope,
|
|
1463
2269
|
resolvePolicy,
|
|
1464
2270
|
resolveSequenceKey,
|
|
1465
2271
|
resolveSession,
|
|
@@ -1483,6 +2289,7 @@ export {
|
|
|
1483
2289
|
sweepBlobIntents,
|
|
1484
2290
|
tokenize,
|
|
1485
2291
|
transitionGuard,
|
|
2292
|
+
unionPageProvider,
|
|
1486
2293
|
unwrapDeksFromBlob,
|
|
1487
2294
|
unwrapDeksFromPaperEntry,
|
|
1488
2295
|
unwrapMagicLinkGrant,
|
|
@@ -1519,6 +2326,7 @@ export {
|
|
|
1519
2326
|
withSearch,
|
|
1520
2327
|
withSequence,
|
|
1521
2328
|
withTeam,
|
|
2329
|
+
withVectorIndex,
|
|
1522
2330
|
withdrawAccessibleData,
|
|
1523
2331
|
wrapPodStore,
|
|
1524
2332
|
wrapStore,
|