@delali/narsil 0.3.1-next.185 → 0.3.1-next.193
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/dist/adapters/filesystem.mjs +2 -2
- package/dist/adapters/gcs.mjs +2 -2
- package/dist/adapters/indexeddb.mjs +1 -1
- package/dist/adapters/s3.mjs +2 -2
- package/dist/browser/chunk-4E5APHTM.mjs +1459 -0
- package/dist/browser/{chunk-4ZICWS4V.mjs → chunk-QAOVAYAG.mjs} +1 -1
- package/dist/browser/{chunk-CPSHS46N.mjs → chunk-UQG4HUGQ.mjs} +82 -50
- package/dist/browser/{chunk-2Q45HI5H.mjs → chunk-YINZFPLT.mjs} +7 -0
- package/dist/browser/{module-XVLHJ7T7.mjs → module-ZZTNG5JZ.mjs} +26 -3
- package/dist/browser/{optional-writes-ZTBHYQMN.mjs → optional-writes-J5BHKEQL.mjs} +21 -8
- package/dist/browser/{storage-leaf-4XMCITJ6.mjs → storage-leaf-N3JMQ6CF.mjs} +14569 -13747
- package/dist/{capabilities-DAHXphRn.d.ts → capabilities-CLnQHIqV.d.ts} +51 -9
- package/dist/{chunk-KLVMK3R5.mjs → chunk-2CKDCC65.mjs} +1 -1
- package/dist/{chunk-CODGHJVW.mjs → chunk-2HVQYOOD.mjs} +40 -12
- package/dist/{chunk-M5I64AQW.mjs → chunk-3N5GUXBI.mjs} +33 -33
- package/dist/{chunk-DU23J5JG.mjs → chunk-5CIHQIA4.mjs} +6 -6
- package/dist/{react-native/chunks/chunk-ZUFOYZ5P.mjs → chunk-62X472AC.mjs} +1 -1
- package/dist/{chunk-QJGDB3WR.mjs → chunk-6GHX35ZM.mjs} +2 -2
- package/dist/{chunk-G3XRHAJA.mjs → chunk-6MC6BCXK.mjs} +3 -3
- package/dist/{chunk-X5NHWOXT.mjs → chunk-7P5YWDRQ.mjs} +2 -2
- package/dist/{chunk-MHBG33R5.mjs → chunk-7X4IIREW.mjs} +76 -46
- package/dist/{chunk-F4OOBPKA.mjs → chunk-AOYQTX6W.mjs} +1 -1
- package/dist/{chunk-D6FYUTFN.mjs → chunk-ASZLNVWW.mjs} +1 -1
- package/dist/{chunk-LR6JJVML.mjs → chunk-D2EJUM4A.mjs} +764 -699
- package/dist/{chunk-FETZYCH7.mjs → chunk-F6F4G322.mjs} +26 -1
- package/dist/{chunk-2YWWHMVC.mjs → chunk-FGOGT273.mjs} +2 -2
- package/dist/{chunk-5BUEBIXR.mjs → chunk-GLXLSPLO.mjs} +18 -5
- package/dist/{chunk-IE3Q62QD.mjs → chunk-GR5GMFJJ.mjs} +1 -1
- package/dist/{chunk-Y7QUFIGV.mjs → chunk-GXED6R3Q.mjs} +2 -2
- package/dist/{chunk-BVZWWMOU.mjs → chunk-HHYQMGPW.mjs} +2 -2
- package/dist/{chunk-SL53DHVE.mjs → chunk-HSA3H3VW.mjs} +121 -68
- package/dist/{chunk-YM2HI5N5.mjs → chunk-IL5DRCNU.mjs} +2 -2
- package/dist/{chunk-JDG6CCXM.mjs → chunk-JENWA4WX.mjs} +2 -2
- package/dist/{chunk-2GONI5HL.mjs → chunk-JXINPXRS.mjs} +5 -4
- package/dist/chunk-K5GNK5GE.mjs +602 -0
- package/dist/{chunk-WLFOLAQI.mjs → chunk-KBU3ZFJN.mjs} +2 -2
- package/dist/{chunk-EDEE7ETQ.mjs → chunk-KOA6T2IC.mjs} +3 -3
- package/dist/{chunk-N3M4NPML.mjs → chunk-M2Z5WVWW.mjs} +1 -1
- package/dist/{chunk-EWGIF6FQ.mjs → chunk-NJJN4FMM.mjs} +1 -1
- package/dist/{chunk-C7YQHCSO.mjs → chunk-P4F4UWLC.mjs} +1 -1
- package/dist/{chunk-VYSWVQCE.mjs → chunk-PAPQGC6I.mjs} +2 -2
- package/dist/{chunk-I2WJCRIH.mjs → chunk-R2PJKSNL.mjs} +1 -1
- package/dist/{chunk-6SZQETSC.mjs → chunk-RORNUNXW.mjs} +5 -2
- package/dist/{chunk-FBQYC5OX.mjs → chunk-SB5HCIIO.mjs} +16 -13
- package/dist/{chunk-CYCVPTTR.mjs → chunk-SCZI7COG.mjs} +2 -2
- package/dist/{chunk-O337MDRJ.mjs → chunk-SHES4VP5.mjs} +38 -13
- package/dist/{chunk-H4QYQ5DE.mjs → chunk-SIIDIGKI.mjs} +2 -2
- package/dist/{chunk-A3OAFUZI.mjs → chunk-SM2SYVIX.mjs} +2 -2
- package/dist/{chunk-II6XF6M4.mjs → chunk-SMLUZGSI.mjs} +9 -8
- package/dist/{chunk-2KCCQK4R.mjs → chunk-TSE2VWPX.mjs} +2 -2
- package/dist/{chunk-WSIU6YXQ.mjs → chunk-YPEJ6ODL.mjs} +1732 -743
- package/dist/{chunk-7WXGUTWK.mjs → chunk-Z6SIJH5O.mjs} +17 -6
- package/dist/{chunk-Q3ZZH5Z7.mjs → chunk-ZKOQR7EA.mjs} +7 -0
- package/dist/{chunk-CKEOTSF5.mjs → chunk-ZS2YUB2L.mjs} +6 -3
- package/dist/{chunk-FCQMZDRI.mjs → chunk-ZVZYJIIP.mjs} +3 -3
- package/dist/{client-DpqtT2XG.d.ts → client-uB0kp2yT.d.ts} +88 -5
- package/dist/client.d.ts +7 -7
- package/dist/client.mjs +3 -1265
- package/dist/{config-D9WR3MhO.d.ts → config-BvHQ-C7U.d.ts} +3 -3
- package/dist/{config-C687-reW.d.ts → config-PqgNY1H7.d.ts} +1 -1
- package/dist/{core-leaf-NEUM7PU3.mjs → core-leaf-TAR3GJVE.mjs} +3 -3
- package/dist/{direct-executor-37IH3ISS.mjs → direct-executor-WSZALYCV.mjs} +8 -8
- package/dist/distribution/coordinator/etcd.d.ts +1 -1
- package/dist/distribution/coordinator/etcd.mjs +35 -15
- package/dist/distribution/coordinator/in-memory.d.ts +1 -1
- package/dist/distribution/coordinator/in-memory.mjs +16 -6
- package/dist/distribution/transport/grpc.mjs +2 -2
- package/dist/distribution/transport/tcp.mjs +2 -2
- package/dist/distribution.d.ts +70 -9
- package/dist/distribution.mjs +1695 -680
- package/dist/{durability-config-NWU2G2SJ.mjs → durability-config-VWS2K24E.mjs} +1 -1
- package/dist/{react-native/chunks/embed-4LBSQD7U.mjs → embed-4PHHKGBK.mjs} +1 -1
- package/dist/embeddings/openai.mjs +2 -2
- package/dist/{engine-De6JzTW8.d.ts → engine-qjAxJSKk.d.ts} +206 -7
- package/dist/{index-CBUl4z3E.d.ts → index-BaQIAnk0.d.ts} +137 -111
- package/dist/index.browser.mjs +3 -3
- package/dist/index.d.ts +4 -4
- package/dist/index.mjs +8 -8
- package/dist/index.react-native.mjs +9 -9
- package/dist/{long-query-thread-DIPJBMV7.mjs → long-query-thread-N2DNPEA3.mjs} +21 -21
- package/dist/{module-Z3CL4GJ4.mjs → module-UQFIJQMG.mjs} +33 -13
- package/dist/{msgpack-leaf-7KBYOVTF.mjs → msgpack-leaf-H5ZYW7S7.mjs} +4 -4
- package/dist/{optional-reads-ENKMVQ4Q.mjs → optional-reads-5HFMF2QZ.mjs} +2 -2
- package/dist/{optional-writes-YIVJMQ4D.mjs → optional-writes-CGDBJBHQ.mjs} +31 -18
- package/dist/{paged-partition-archive-IZ6U7DVN.mjs → paged-partition-archive-UK44CVXG.mjs} +20 -20
- package/dist/partial-words.browser.mjs +3 -3
- package/dist/partial-words.mjs +8 -8
- package/dist/pattern.browser.mjs +2 -2
- package/dist/pattern.mjs +3 -3
- package/dist/persistence/durability/checkpoint-worker.d.ts +7 -0
- package/dist/persistence/durability/checkpoint-worker.mjs +18 -18
- package/dist/{phrase-module-ZY3TLTQA.mjs → phrase-module-EFESWOCR.mjs} +2 -2
- package/dist/{query-actions-7EOKT3WD.mjs → query-actions-7BL3YZDW.mjs} +8 -8
- package/dist/query-suggestions/merge-worker.mjs +11 -11
- package/dist/query-suggestions.browser.mjs +3 -3
- package/dist/query-suggestions.d.ts +1 -1
- package/dist/query-suggestions.mjs +9 -9
- package/dist/react-native/chunks/{chunk-TQ26BKBH.mjs → chunk-43R4GCM7.mjs} +7 -0
- package/dist/react-native/chunks/{chunk-CBU4M3EU.mjs → chunk-63DZ26X5.mjs} +277 -75
- package/dist/react-native/chunks/{chunk-BN6FUB7N.mjs → chunk-AN4HKLB4.mjs} +1 -1
- package/dist/react-native/chunks/{chunk-T5HF3FW3.mjs → chunk-BNFGA7TY.mjs} +3 -3
- package/dist/react-native/chunks/{chunk-PVMEHBQO.mjs → chunk-CW2ZFXSE.mjs} +1 -1
- package/dist/react-native/chunks/{chunk-NLEFMPY3.mjs → chunk-G434H5WG.mjs} +15 -4
- package/dist/react-native/chunks/{chunk-SK3DPAI4.mjs → chunk-HTBY4GON.mjs} +2 -2
- package/dist/react-native/chunks/{chunk-ZQPSXN6C.mjs → chunk-IP3QLETQ.mjs} +5 -5
- package/dist/react-native/chunks/{chunk-7TPO4FLE.mjs → chunk-LOKGE4OQ.mjs} +3 -3
- package/dist/react-native/chunks/{chunk-ZDDJVR7X.mjs → chunk-MRH36RN3.mjs} +2 -2
- package/dist/react-native/chunks/{chunk-YOTP2FPE.mjs → chunk-UO44MA5M.mjs} +1 -1
- package/dist/{chunk-4JBTALUC.mjs → react-native/chunks/chunk-UYAZLGEM.mjs} +1 -1
- package/dist/react-native/chunks/{chunk-WFQ6YQZA.mjs → chunk-UYKIV2KT.mjs} +1 -1
- package/dist/react-native/chunks/{chunk-IEY4DARA.mjs → chunk-XHYOQ4K4.mjs} +2 -2
- package/dist/react-native/chunks/{chunk-OZ3XEM6D.mjs → chunk-ZUJCUPVS.mjs} +1 -1
- package/dist/react-native/chunks/{core-leaf-TPBRRWVN.mjs → core-leaf-5PVST5PR.mjs} +4 -4
- package/dist/react-native/chunks/{durability-config-RVTWSXPH.mjs → durability-config-FCSD4MXY.mjs} +1 -1
- package/dist/{embed-2QMYCD2Q.mjs → react-native/chunks/embed-HA2I7RCF.mjs} +1 -1
- package/dist/react-native/chunks/{gzip.react-native-DLO4WW27.mjs → gzip.react-native-CVM4NQG2.mjs} +2 -2
- package/dist/react-native/chunks/{module-COLNJNML.mjs → module-QRCYB7QV.mjs} +32 -9
- package/dist/react-native/chunks/msgpack-leaf-JMNGSTRW.mjs +7 -0
- package/dist/react-native/chunks/{optional-reads-74HYI4DO.mjs → optional-reads-AFPO2FEB.mjs} +3 -3
- package/dist/react-native/chunks/{optional-writes-QETIM6BI.mjs → optional-writes-GC6JWMAF.mjs} +31 -18
- package/dist/react-native/chunks/{phrase-module-UC4YGEBB.mjs → phrase-module-IGYBK7XH.mjs} +3 -3
- package/dist/react-native/chunks/{resolve-vector-text-FU7D4QP5.mjs → resolve-vector-text-GE2CRJKI.mjs} +1 -1
- package/dist/react-native/chunks/{restore-queue-3E2MJIJS.mjs → restore-queue-2ACONS4W.mjs} +12 -12
- package/dist/react-native/chunks/{segment-codec-leaf-IE4DXUZV.mjs → segment-codec-leaf-SSIWXVUG.mjs} +10 -10
- package/dist/react-native/chunks/{segment-merge-leaf-62LQ5WZB.mjs → segment-merge-leaf-I2WDFE6O.mjs} +11 -11
- package/dist/react-native/chunks/{storage-leaf-LNOLKWZB.mjs → storage-leaf-YXXMG4VR.mjs} +14727 -13915
- package/dist/react-native/chunks/{store-leaf-Y7CBOPFZ.mjs → store-leaf-FS7A4PZA.mjs} +11 -11
- package/dist/react-native/chunks/{suggestions-leaf-PSUGL6MI.mjs → suggestions-leaf-PSFCT5EX.mjs} +11 -11
- package/dist/react-native/chunks/{worker-copies-MW5O5U3D.mjs → worker-copies-QRMISMEL.mjs} +10 -10
- package/dist/react-native/partial-words.mjs +9 -9
- package/dist/react-native/pattern.mjs +5 -5
- package/dist/react-native/query-suggestions.mjs +9 -9
- package/dist/react-native/sync.mjs +433 -51
- package/dist/react-native/synonyms.mjs +9 -9
- package/dist/react.d.ts +8 -8
- package/dist/react.mjs +7 -0
- package/dist/{rerank-KTV5L7MZ.mjs → rerank-4GFC26FD.mjs} +8 -8
- package/dist/rerankers/http.mjs +2 -2
- package/dist/{resolve-vector-text-SD6BEMKZ.mjs → resolve-vector-text-OD4J3WHF.mjs} +2 -2
- package/dist/{restore-queue-ES7TDJ5V.mjs → restore-queue-E4EIUYVV.mjs} +11 -11
- package/dist/{segment-codec-leaf-DO75VKEV.mjs → segment-codec-leaf-MP6DILVE.mjs} +9 -9
- package/dist/{segment-merge-leaf-JGND6LG5.mjs → segment-merge-leaf-ED2NMUC5.mjs} +9 -9
- package/dist/server.d.ts +13 -9
- package/dist/server.mjs +875 -348
- package/dist/{storage-leaf-ZI3H2WJY.mjs → storage-leaf-HQFO37W7.mjs} +5234 -5835
- package/dist/{store-leaf-YIH36Y5J.mjs → store-leaf-PL2G7RM5.mjs} +10 -10
- package/dist/{suggestions-leaf-FP5HSTFP.mjs → suggestions-leaf-I3MEHACP.mjs} +12 -12
- package/dist/sync/filesystem.d.ts +2 -2
- package/dist/sync/filesystem.mjs +16 -16
- package/dist/sync/indexeddb.browser.mjs +1 -1
- package/dist/sync/indexeddb.d.ts +2 -2
- package/dist/sync/indexeddb.mjs +3 -3
- package/dist/sync.browser.mjs +35 -1108
- package/dist/sync.d.ts +3 -3
- package/dist/sync.mjs +430 -51
- package/dist/synonyms.browser.mjs +3 -3
- package/dist/synonyms.mjs +8 -8
- package/dist/{tasks-X2IJQc8J.d.ts → tasks-C65V7lIr.d.ts} +3 -3
- package/dist/thread-LTFI3RK5.mjs +31 -0
- package/dist/{types-D0YasjoX.d.ts → types-CpCg-Gq-.d.ts} +1 -1
- package/dist/vector/search-worker.mjs +5 -5
- package/dist/{worker-copies-WYPRCNB7.mjs → worker-copies-P7YWXEP5.mjs} +11 -11
- package/dist/workers/entry.mjs +14 -14
- package/openapi.json +144 -0
- package/package.json +5 -7
- package/dist/chunk-URVH6BLO.mjs +0 -217
- package/dist/react-native/chunks/msgpack-leaf-GTKLF6GJ.mjs +0 -7
- package/dist/thread-NQRNW3IH.mjs +0 -31
- /package/dist/{chunk-CV3Q2EKO.mjs → chunk-S5QMWECL.mjs} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { E as EmbeddingAdapter, R as RerankAdapter } from './adapters-pljAqmrC.js';
|
|
2
|
-
import { C as ClusterNamespace } from './config-
|
|
2
|
+
import { C as ClusterNamespace } from './config-BvHQ-C7U.js';
|
|
3
3
|
import { l as RecordedQuery } from './query-suggestions-CBYkrQ5T.js';
|
|
4
|
-
import { E as ErrorDetail, j as TaskStore } from './tasks-
|
|
4
|
+
import { E as ErrorDetail, j as TaskStore } from './tasks-C65V7lIr.js';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Context handed to {@link OnRequestHook} for every inbound request, captured
|
|
@@ -37,9 +37,10 @@ interface RequestDenial {
|
|
|
37
37
|
}
|
|
38
38
|
/**
|
|
39
39
|
* Returned by an {@link OnRequestHook} to admit a request under a credential
|
|
40
|
-
* that expires. The server closes a device sync feed
|
|
41
|
-
* `expiresAt`, so that
|
|
42
|
-
* it treats the grant on every other route as
|
|
40
|
+
* that expires. The server closes a device sync feed or a change feed with
|
|
41
|
+
* close code 4401 at `expiresAt`, so that the peer has to reconnect with a
|
|
42
|
+
* fresh credential, and it treats the grant on every other route as
|
|
43
|
+
* `undefined`.
|
|
43
44
|
*
|
|
44
45
|
* @public
|
|
45
46
|
*/
|
|
@@ -50,9 +51,10 @@ interface RequestGrant {
|
|
|
50
51
|
/**
|
|
51
52
|
* Runs before every routed request, which is where authentication, rate
|
|
52
53
|
* limiting, and any other admission rule goes. It also runs on the upgrade
|
|
53
|
-
* of a device sync feed, where a browser
|
|
54
|
-
* a `Sec-WebSocket-Protocol` value after `narsil.sync.v1
|
|
55
|
-
* can set no other header on a
|
|
54
|
+
* of a device sync feed or a change feed, where a browser can carry its
|
|
55
|
+
* credential as a `Sec-WebSocket-Protocol` value after `narsil.sync.v1` or
|
|
56
|
+
* `narsil.changes.v1`, because a browser can set no other header on a
|
|
57
|
+
* WebSocket.
|
|
56
58
|
*
|
|
57
59
|
* @param ctx - The request's method, path, headers, and peer address.
|
|
58
60
|
* @returns A {@link RequestDenial} to reject the request, a
|
|
@@ -90,6 +92,35 @@ interface ServerSyncOptions {
|
|
|
90
92
|
*/
|
|
91
93
|
maxBufferedBytes?: number;
|
|
92
94
|
}
|
|
95
|
+
/**
|
|
96
|
+
* The settings of the change feed at `GET /indexes/{name}/changes/feed`. Every
|
|
97
|
+
* field has a default, and the server counts the connections and the
|
|
98
|
+
* catch-ups of this feed apart from those of the device sync feed.
|
|
99
|
+
*
|
|
100
|
+
* @public
|
|
101
|
+
*/
|
|
102
|
+
interface ServerChangesOptions {
|
|
103
|
+
/**
|
|
104
|
+
* The server stops sending changes to a subscriber while the changes that
|
|
105
|
+
* it has sent, and that the subscriber has not acknowledged, hold more than
|
|
106
|
+
* this many bytes. It defaults to 8,388,608.
|
|
107
|
+
*/
|
|
108
|
+
windowBytes?: number;
|
|
109
|
+
/** The server holds at most this many change feed connections, and it answers 429 to one more. It defaults to 10,000. */
|
|
110
|
+
maxConnections?: number;
|
|
111
|
+
/**
|
|
112
|
+
* The server reads the history of at most this many change feed
|
|
113
|
+
* connections at once, and it holds any other connection until one of
|
|
114
|
+
* those reads ends. It defaults to 32.
|
|
115
|
+
*/
|
|
116
|
+
maxCatchUps?: number;
|
|
117
|
+
/**
|
|
118
|
+
* The server stops reading changes for every subscriber while its change
|
|
119
|
+
* feed connections hold this many bytes that the network has not yet
|
|
120
|
+
* taken. It defaults to 268,435,456.
|
|
121
|
+
*/
|
|
122
|
+
maxBufferedBytes?: number;
|
|
123
|
+
}
|
|
93
124
|
/**
|
|
94
125
|
* Which cross-origin requests the server accepts.
|
|
95
126
|
*
|
|
@@ -266,6 +297,17 @@ interface ServerOptions {
|
|
|
266
297
|
* settings.
|
|
267
298
|
*/
|
|
268
299
|
sync?: boolean | ServerSyncOptions;
|
|
300
|
+
/**
|
|
301
|
+
* Turns on the change feed, a WebSocket at
|
|
302
|
+
* `GET /indexes/{name}/changes/feed`, which stays off by default. Each index
|
|
303
|
+
* serves it only once a caller turns capture on for it with
|
|
304
|
+
* `updateChanges`. A subscriber receives every document of the index, so
|
|
305
|
+
* the server refuses to start with the feed on and no
|
|
306
|
+
* {@link ServerOptions.onRequest} hook, whatever
|
|
307
|
+
* {@link ServerOptions.allowInsecure} holds. Pass `true` for the default
|
|
308
|
+
* settings.
|
|
309
|
+
*/
|
|
310
|
+
changes?: boolean | ServerChangesOptions;
|
|
269
311
|
/**
|
|
270
312
|
* Lets `POST /indexes/{name}/query-suggestions/record` count searches. The
|
|
271
313
|
* server takes the person and the group from
|
|
@@ -421,4 +463,4 @@ declare const BM25_TUNING_CAPABILITY = "indexes.bm25";
|
|
|
421
463
|
*/
|
|
422
464
|
declare const SERVER_CAPABILITIES: readonly string[];
|
|
423
465
|
|
|
424
|
-
export { ASYNC_IMPORT_CAPABILITY as A, BM25_TUNING_CAPABILITY as B, CHANGE_ANALYSIS_CAPABILITY as C, DOCUMENT_EXPORT_CAPABILITY as D, type ErrorEnvelope as E, INDEX_LIFECYCLE_CAPABILITY as I, type NarsilServer as N, type OnRequestHook as O, type QueryIdentity as Q, REBUILD_ANALYSIS_CAPABILITY as R, SERVER_CAPABILITIES as S, TASK_CANCEL_CAPABILITY as T, SYNONYMS_CAPABILITY as a, TASK_FILTER_CAPABILITY as b, type ServerOptions as c, type CorsOptions as d, type RequestContext as e, type RequestDenial as f, type RequestGrant as g, type
|
|
466
|
+
export { ASYNC_IMPORT_CAPABILITY as A, BM25_TUNING_CAPABILITY as B, CHANGE_ANALYSIS_CAPABILITY as C, DOCUMENT_EXPORT_CAPABILITY as D, type ErrorEnvelope as E, INDEX_LIFECYCLE_CAPABILITY as I, type NarsilServer as N, type OnRequestHook as O, type QueryIdentity as Q, REBUILD_ANALYSIS_CAPABILITY as R, SERVER_CAPABILITIES as S, TASK_CANCEL_CAPABILITY as T, SYNONYMS_CAPABILITY as a, TASK_FILTER_CAPABILITY as b, type ServerOptions as c, type CorsOptions as d, type RequestContext as e, type RequestDenial as f, type RequestGrant as g, type ServerChangesOptions as h, type ServerLimits as i, type ServerQuerySuggestionsOptions as j, type ServerSyncOptions as k };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MAX_DOCUMENT_ENCODING_DEPTH, DOCUMENT_ENCODER_RETAINED_BUFFER_BYTES, DOCUMENT_REPLY_ENVELOPE_DEPTH } from './chunk-4PY4JYMY.mjs';
|
|
2
|
-
import { NarsilError, ErrorCodes } from './chunk-
|
|
2
|
+
import { NarsilError, ErrorCodes } from './chunk-ZKOQR7EA.mjs';
|
|
3
3
|
import { encode, Encoder } from '@msgpack/msgpack';
|
|
4
4
|
|
|
5
5
|
var integerEncoder;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { restoredEmbedding, restoredPartitionConfig, readSharedConfigFields } from './chunk-
|
|
1
|
+
import { restoredEmbedding, restoredPartitionConfig, readSharedConfigFields } from './chunk-M2Z5WVWW.mjs';
|
|
2
2
|
import { MAX_PARTITION_COUNT, MAX_REPLICATION_FACTOR } from './chunk-JDDXV6UF.mjs';
|
|
3
|
-
import { storedStateOf } from './chunk-
|
|
4
|
-
import { getLanguage, generateId, decodeSynonymRules } from './chunk-
|
|
3
|
+
import { storedStateOf } from './chunk-KOA6T2IC.mjs';
|
|
4
|
+
import { getLanguage, generateId, decodeSynonymRules } from './chunk-HSA3H3VW.mjs';
|
|
5
5
|
import { decode } from './chunk-GXCDWLQI.mjs';
|
|
6
6
|
import { isSyncEpoch } from './chunk-BUMREPLU.mjs';
|
|
7
7
|
import { MAX_INDEX_NAME_LENGTH, INDEX_NAME_PATTERN } from './chunk-3ECIRFS5.mjs';
|
|
8
|
-
import { NarsilError, ErrorCodes } from './chunk-
|
|
8
|
+
import { NarsilError, ErrorCodes } from './chunk-ZKOQR7EA.mjs';
|
|
9
9
|
import { compareCodePoints } from './chunk-TGPKS2UM.mjs';
|
|
10
10
|
import { encode } from '@msgpack/msgpack';
|
|
11
11
|
|
|
@@ -57,6 +57,8 @@ var DEFAULT_NODE_LIFECYCLE_CONFIG = {
|
|
|
57
57
|
nodeHeartbeatIntervalMs: 1e4
|
|
58
58
|
};
|
|
59
59
|
var MAX_SYNONYM_GENERATION_LENGTH = 128;
|
|
60
|
+
var UNFED_REPLICA_CHECK_INTERVAL_MS = 1e3;
|
|
61
|
+
var UNFED_REPLICA_RESYNC_MS = 15e3;
|
|
60
62
|
function decodeClusterQuerySuggestionSettings(raw, reject) {
|
|
61
63
|
let state;
|
|
62
64
|
try {
|
|
@@ -97,14 +99,16 @@ function metadataWithSuggestionState(snapshot, state) {
|
|
|
97
99
|
function isPositiveSafeInteger(value) {
|
|
98
100
|
return typeof value === "number" && Number.isSafeInteger(value) && value >= 1;
|
|
99
101
|
}
|
|
100
|
-
function
|
|
101
|
-
if (!isRecord2(raw) || typeof raw.enabled !== "boolean")
|
|
102
|
+
function decodeHistorySetting(field, raw, reject) {
|
|
103
|
+
if (!isRecord2(raw) || typeof raw.enabled !== "boolean") {
|
|
104
|
+
return reject(`${field} must be a map with a boolean enabled`);
|
|
105
|
+
}
|
|
102
106
|
const { historyMaxAgeMs, historyMaxBytes } = raw;
|
|
103
107
|
if (historyMaxAgeMs !== void 0 && !isPositiveSafeInteger(historyMaxAgeMs)) {
|
|
104
|
-
return reject(
|
|
108
|
+
return reject(`${field}.historyMaxAgeMs must be a positive whole number`);
|
|
105
109
|
}
|
|
106
110
|
if (historyMaxBytes !== void 0 && !isPositiveSafeInteger(historyMaxBytes)) {
|
|
107
|
-
return reject(
|
|
111
|
+
return reject(`${field}.historyMaxBytes must be a positive whole number`);
|
|
108
112
|
}
|
|
109
113
|
return {
|
|
110
114
|
enabled: raw.enabled,
|
|
@@ -112,8 +116,17 @@ function decodeSyncSetting(raw, reject) {
|
|
|
112
116
|
...historyMaxBytes !== void 0 ? { historyMaxBytes } : {}
|
|
113
117
|
};
|
|
114
118
|
}
|
|
119
|
+
function decodeChangesSetting(raw, reject) {
|
|
120
|
+
const history = decodeHistorySetting("changes", raw, reject);
|
|
121
|
+
const previousDocument = isRecord2(raw) ? raw.previousDocument : void 0;
|
|
122
|
+
if (previousDocument !== void 0 && typeof previousDocument !== "boolean") {
|
|
123
|
+
return reject("changes.previousDocument must be a boolean");
|
|
124
|
+
}
|
|
125
|
+
return { ...history, ...previousDocument === true ? { previousDocument } : {} };
|
|
126
|
+
}
|
|
115
127
|
function decodeClusterSyncSettings(raw, reject) {
|
|
116
|
-
const sync = raw.sync === void 0 ? void 0 :
|
|
128
|
+
const sync = raw.sync === void 0 ? void 0 : decodeHistorySetting("sync", raw.sync, reject);
|
|
129
|
+
const changes = raw.changes === void 0 ? void 0 : decodeChangesSetting(raw.changes, reject);
|
|
117
130
|
if (raw.syncActive !== void 0 && typeof raw.syncActive !== "boolean") {
|
|
118
131
|
return reject("syncActive must be a boolean");
|
|
119
132
|
}
|
|
@@ -123,9 +136,13 @@ function decodeClusterSyncSettings(raw, reject) {
|
|
|
123
136
|
return {
|
|
124
137
|
...sync !== void 0 ? { sync } : {},
|
|
125
138
|
...raw.syncActive !== void 0 ? { syncActive: raw.syncActive } : {},
|
|
126
|
-
...raw.syncEpoch !== void 0 ? { syncEpoch: raw.syncEpoch } : {}
|
|
139
|
+
...raw.syncEpoch !== void 0 ? { syncEpoch: raw.syncEpoch } : {},
|
|
140
|
+
...changes !== void 0 ? { changes } : {}
|
|
127
141
|
};
|
|
128
142
|
}
|
|
143
|
+
function epochFeaturesOn(settings) {
|
|
144
|
+
return settings?.sync?.enabled === true || settings?.changes?.enabled === true;
|
|
145
|
+
}
|
|
129
146
|
function metadataWithSync(snapshot, next) {
|
|
130
147
|
const decoded = decode(snapshot.bytes);
|
|
131
148
|
const fields = isRecord2(decoded) ? decoded : {};
|
|
@@ -133,9 +150,19 @@ function metadataWithSync(snapshot, next) {
|
|
|
133
150
|
return new Uint8Array(encode({ ...fields, settings: { ...settings, ...next } }, { ignoreUndefined: true }));
|
|
134
151
|
}
|
|
135
152
|
function withoutSyncFields(settings) {
|
|
136
|
-
const { sync: _sync, syncActive: _active, syncEpoch: _epoch, ...rest } = settings;
|
|
153
|
+
const { sync: _sync, syncActive: _active, syncEpoch: _epoch, changes: _changes, ...rest } = settings;
|
|
137
154
|
return rest;
|
|
138
155
|
}
|
|
156
|
+
function syncSettingsOfSnapshot(snapshot) {
|
|
157
|
+
const settings = snapshot.settings;
|
|
158
|
+
if (settings === void 0) return {};
|
|
159
|
+
return {
|
|
160
|
+
...settings.sync !== void 0 ? { sync: settings.sync } : {},
|
|
161
|
+
...settings.syncActive !== void 0 ? { syncActive: settings.syncActive } : {},
|
|
162
|
+
...settings.syncEpoch !== void 0 ? { syncEpoch: settings.syncEpoch } : {},
|
|
163
|
+
...settings.changes !== void 0 ? { changes: settings.changes } : {}
|
|
164
|
+
};
|
|
165
|
+
}
|
|
139
166
|
|
|
140
167
|
// src/distribution/cluster/synonym-set.ts
|
|
141
168
|
var SYNONYM_CHUNK_BYTES = 1048576;
|
|
@@ -406,6 +433,7 @@ function indexConfigFromSettings(schema, settings, indexName) {
|
|
|
406
433
|
sync: _sync,
|
|
407
434
|
syncActive: _syncActive,
|
|
408
435
|
syncEpoch: _syncEpoch,
|
|
436
|
+
changes: _changes,
|
|
409
437
|
querySuggestions: _querySuggestions,
|
|
410
438
|
bannedQueries: _bannedQueries,
|
|
411
439
|
querySuggestionsSource: _querySuggestionsSource,
|
|
@@ -667,4 +695,4 @@ function storedSynonymSetOf(bytes) {
|
|
|
667
695
|
return ref === null ? null : { indexUuid: decoded.indexUuid, ref };
|
|
668
696
|
}
|
|
669
697
|
|
|
670
|
-
export { ALLOCATION_CAS_ATTEMPTS, ALLOCATION_RETRY_DELAY_MS, ANALYSIS_CHANGE_POLL_INTERVAL_MS, ANALYSIS_CHANGE_RETRY_MS, ANALYSIS_REBUILD_RESEND_MS, BOOTSTRAP_CAS_ATTEMPTS, DEFAULT_CONTROLLER_CONFIG, DEFAULT_NODE_LIFECYCLE_CONFIG, ESTIMATED_PARTITION_BYTES, HIDDEN_GENERATION_PREFIX, LEADERSHIP_IMBALANCE_THRESHOLD, MAX_RESHARD_CUTOVER_ATTEMPTS, PARTITION_STORES_TIMEOUT_MS, REBALANCE_THRESHOLD, RECOVERY_CAS_ATTEMPTS, RESHARD_CONTROLLER_POLL_INTERVAL_MS, RESHARD_CUTOVER_LAG_ENTRIES, RESHARD_CUTOVER_TIMEOUT_MS, RESHARD_FORWARD_BATCH_DOCUMENTS, RESHARD_POLL_INTERVAL_MS, RESHARD_RECORD_CAS_ATTEMPTS, RESHARD_RECORD_CHECK_INTERVAL_MS, RESHARD_RETRY_DELAY_MS, SYNC_EPOCH_CAS_ATTEMPTS, TEARDOWN_CAS_ATTEMPTS, TEARDOWN_RETRY_DELAY_MS, TEARDOWN_RETRY_ROUNDS, decodeIndexSettings, deleteSynonymSet, getClusterIndexConfig, getIndexMetadata, indexConfigFromSettings, indexConfigKey, indexMetadataSnapshotOf, indexSettingsOf, indexUuidOfStoredMetadata, isRecord, isRecord2, isValidInteger, metadataWithBm25, metadataWithSuggestionState, metadataWithSync, metadataWithSynonymSet, putGenerationMetadata, putIndexMetadata, putIndexReplicationFactor, readIndexMetadataSnapshot, readIndexState, storeSynonymSet, storedSynonymSetOf, suggestionStateOfSettings, validateIndexName, withPartitionCount };
|
|
698
|
+
export { ALLOCATION_CAS_ATTEMPTS, ALLOCATION_RETRY_DELAY_MS, ANALYSIS_CHANGE_POLL_INTERVAL_MS, ANALYSIS_CHANGE_RETRY_MS, ANALYSIS_REBUILD_RESEND_MS, BOOTSTRAP_CAS_ATTEMPTS, DEFAULT_CONTROLLER_CONFIG, DEFAULT_NODE_LIFECYCLE_CONFIG, ESTIMATED_PARTITION_BYTES, HIDDEN_GENERATION_PREFIX, LEADERSHIP_IMBALANCE_THRESHOLD, MAX_RESHARD_CUTOVER_ATTEMPTS, PARTITION_STORES_TIMEOUT_MS, REBALANCE_THRESHOLD, RECOVERY_CAS_ATTEMPTS, RESHARD_CONTROLLER_POLL_INTERVAL_MS, RESHARD_CUTOVER_LAG_ENTRIES, RESHARD_CUTOVER_TIMEOUT_MS, RESHARD_FORWARD_BATCH_DOCUMENTS, RESHARD_POLL_INTERVAL_MS, RESHARD_RECORD_CAS_ATTEMPTS, RESHARD_RECORD_CHECK_INTERVAL_MS, RESHARD_RETRY_DELAY_MS, SYNC_EPOCH_CAS_ATTEMPTS, TEARDOWN_CAS_ATTEMPTS, TEARDOWN_RETRY_DELAY_MS, TEARDOWN_RETRY_ROUNDS, UNFED_REPLICA_CHECK_INTERVAL_MS, UNFED_REPLICA_RESYNC_MS, decodeIndexSettings, deleteSynonymSet, epochFeaturesOn, getClusterIndexConfig, getIndexMetadata, indexConfigFromSettings, indexConfigKey, indexMetadataSnapshotOf, indexSettingsOf, indexUuidOfStoredMetadata, isRecord, isRecord2, isValidInteger, metadataWithBm25, metadataWithSuggestionState, metadataWithSync, metadataWithSynonymSet, putGenerationMetadata, putIndexMetadata, putIndexReplicationFactor, readIndexMetadataSnapshot, readIndexState, storeSynonymSet, storedSynonymSetOf, suggestionStateOfSettings, syncSettingsOfSnapshot, validateIndexName, withPartitionCount };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { SEGMENT_MANIFEST_VERSION, MANIFEST_ENVELOPE_VERSION } from './chunk-
|
|
2
|
-
import { encode } from './chunk-
|
|
3
|
-
import { createFixedBuffer, createVectorFileReader } from './chunk-
|
|
4
|
-
import { crc32, packChecksummedEnvelope, HEADER_SIZE } from './chunk-
|
|
1
|
+
import { SEGMENT_MANIFEST_VERSION, MANIFEST_ENVELOPE_VERSION } from './chunk-TSE2VWPX.mjs';
|
|
2
|
+
import { encode } from './chunk-S5QMWECL.mjs';
|
|
3
|
+
import { createFixedBuffer, createVectorFileReader } from './chunk-KBU3ZFJN.mjs';
|
|
4
|
+
import { crc32, packChecksummedEnvelope, HEADER_SIZE } from './chunk-KOA6T2IC.mjs';
|
|
5
5
|
import { decode } from './chunk-GXCDWLQI.mjs';
|
|
6
|
-
import { nativeSearchCoreIsEnabled, loadNativeCore } from './chunk-
|
|
7
|
-
import { ErrorCodes, NarsilError } from './chunk-
|
|
6
|
+
import { nativeSearchCoreIsEnabled, loadNativeCore } from './chunk-ASZLNVWW.mjs';
|
|
7
|
+
import { ErrorCodes, NarsilError } from './chunk-ZKOQR7EA.mjs';
|
|
8
8
|
|
|
9
9
|
// src/persistence/durability/segment/store.ts
|
|
10
10
|
function directoryCheckpointStore(directory) {
|
|
@@ -280,33 +280,6 @@ function encodeSegmentManifest(manifest) {
|
|
|
280
280
|
return packChecksummedEnvelope([payload], MANIFEST_ENVELOPE_VERSION, "segment manifest");
|
|
281
281
|
}
|
|
282
282
|
|
|
283
|
-
// src/persistence/paged/constants.ts
|
|
284
|
-
var THREAD_READ_CACHE_BYTES = 134217728;
|
|
285
|
-
var NATIVE_PAGE_CACHE_SHARE = 0.25;
|
|
286
|
-
var NATIVE_ASYNC_PAGE_CACHES = 4;
|
|
287
|
-
var MERGE_READ_CACHE_BYTES = 33554432;
|
|
288
|
-
var MERGED_SEGMENT_TARGET_BYTES = 1073741824;
|
|
289
|
-
var MERGED_SEGMENT_GROWTH_ALLOWANCE = 1.01;
|
|
290
|
-
var SECTION_WRITE_BUFFER_BYTES = 1048576;
|
|
291
|
-
var REMOVAL_BUCKET_WRITE_BUFFER_BYTES = 262144;
|
|
292
|
-
var REMOVAL_BUCKET_TARGET_BYTES = 67108864;
|
|
293
|
-
var LARGEST_REMOVAL_BUCKET_COUNT = 256;
|
|
294
|
-
var WRITER_YIELD_INTERVAL_TOKENS = 4096;
|
|
295
|
-
var FILE_ASSEMBLY_CHUNK_BYTES = 4194304;
|
|
296
|
-
var LARGEST_CACHED_ENTRY_SHARE = 0.25;
|
|
297
|
-
var MAX_THREAD_FILE_NUMBER = 524288;
|
|
298
|
-
var LIST_VIEWS_HELD_PER_SEGMENT = 16384;
|
|
299
|
-
var COLD_LOAD_WAIT_WITHOUT_SEARCH_MS = 400;
|
|
300
|
-
var TOMBSTONES_BETWEEN_YIELDS = 4096;
|
|
301
|
-
var STABLE_HEAD_ATTEMPTS = 8;
|
|
302
|
-
var COLD_WALK_NODES_READ_AHEAD = 8;
|
|
303
|
-
var COLD_GRAPH_PART_VECTORS = 16384;
|
|
304
|
-
var READ_AHEAD_CHUNK_BYTES = 1048576;
|
|
305
|
-
var READS_AHEAD_AT_ONCE = 4;
|
|
306
|
-
var REWRITE_SPILL_BYTES = 134217728;
|
|
307
|
-
var POSTING_WRITE_ROWS = 1024;
|
|
308
|
-
var POSTING_WRITE_POSITIONS = 4096;
|
|
309
|
-
|
|
310
283
|
// src/persistence/paged/native-file.ts
|
|
311
284
|
var PAGE_CORRUPT = -9;
|
|
312
285
|
function requireNativePage(status, path, section, page) {
|
|
@@ -345,6 +318,33 @@ function nativeSection(file, section) {
|
|
|
345
318
|
};
|
|
346
319
|
}
|
|
347
320
|
|
|
321
|
+
// src/persistence/paged/constants.ts
|
|
322
|
+
var THREAD_READ_CACHE_BYTES = 134217728;
|
|
323
|
+
var NATIVE_PAGE_CACHE_SHARE = 0.25;
|
|
324
|
+
var NATIVE_ASYNC_PAGE_CACHES = 4;
|
|
325
|
+
var MERGE_READ_CACHE_BYTES = 33554432;
|
|
326
|
+
var MERGED_SEGMENT_TARGET_BYTES = 1073741824;
|
|
327
|
+
var MERGED_SEGMENT_GROWTH_ALLOWANCE = 1.01;
|
|
328
|
+
var SECTION_WRITE_BUFFER_BYTES = 1048576;
|
|
329
|
+
var REMOVAL_BUCKET_WRITE_BUFFER_BYTES = 262144;
|
|
330
|
+
var REMOVAL_BUCKET_TARGET_BYTES = 67108864;
|
|
331
|
+
var LARGEST_REMOVAL_BUCKET_COUNT = 256;
|
|
332
|
+
var WRITER_YIELD_INTERVAL_TOKENS = 4096;
|
|
333
|
+
var FILE_ASSEMBLY_CHUNK_BYTES = 4194304;
|
|
334
|
+
var LARGEST_CACHED_ENTRY_SHARE = 0.25;
|
|
335
|
+
var MAX_THREAD_FILE_NUMBER = 524288;
|
|
336
|
+
var LIST_VIEWS_HELD_PER_SEGMENT = 16384;
|
|
337
|
+
var COLD_LOAD_WAIT_WITHOUT_SEARCH_MS = 400;
|
|
338
|
+
var TOMBSTONES_BETWEEN_YIELDS = 4096;
|
|
339
|
+
var STABLE_HEAD_ATTEMPTS = 8;
|
|
340
|
+
var COLD_WALK_NODES_READ_AHEAD = 8;
|
|
341
|
+
var COLD_GRAPH_PART_VECTORS = 16384;
|
|
342
|
+
var READ_AHEAD_CHUNK_BYTES = 1048576;
|
|
343
|
+
var READS_AHEAD_AT_ONCE = 4;
|
|
344
|
+
var REWRITE_SPILL_BYTES = 134217728;
|
|
345
|
+
var POSTING_WRITE_ROWS = 1024;
|
|
346
|
+
var POSTING_WRITE_POSITIONS = 4096;
|
|
347
|
+
|
|
348
348
|
// src/persistence/paged/page-cache.ts
|
|
349
349
|
var SLOT_BYTES = 65536;
|
|
350
350
|
var SLOT_METADATA_BYTES = 3 * BigUint64Array.BYTES_PER_ELEMENT + 2 * Uint32Array.BYTES_PER_ELEMENT;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { encode, Merger } from './chunk-
|
|
2
|
-
import { DayStore, RestoredHistory, dayOf, sameBytes } from './chunk-
|
|
1
|
+
import { encode, Merger } from './chunk-FGOGT273.mjs';
|
|
2
|
+
import { DayStore, RestoredHistory, dayOf, sameBytes } from './chunk-6MC6BCXK.mjs';
|
|
3
3
|
import { oneSyncChangeAtATime } from './chunk-V6EUBAIT.mjs';
|
|
4
|
-
import { isGroup, invalidSetting, historyFilesOf, buildRecordKey, MIN_KEY_BYTES, resolveSetting, isPerson, acceptedPhrase, removeHistoryFolder, normaliseBan, banListFromInput, validateSetting, withState, packEnvelopeWithChecksum, crc32, openChecksummedEnvelope, SCRAMBLED_ID_BYTES, KEY_FINGERPRINT_LABEL, KEY_FINGERPRINT_BYTES, removeRestoreLeftovers, HISTORY_SWEEP_INTERVAL_MS, SCHEDULE_OFF, parseSchedule, nextMatchAfter, latestMatchAtOrBefore, DAY_MS, listHistoryFolder, historyFileOf, MAX_MANUAL_SUGGESTION_COUNT, MAX_SOURCE_INDEX_NAME_LENGTH, DEFAULT_PREVIEW_LIMIT, MAX_PREVIEW_LIMIT, requireFieldsInSchema, MAX_TIMER_DELAY_MS, BUILD_WRITE_BATCH, BYTES_PER_MIB, MS_PER_SECOND, BUILD_LIST_PAGE, unionOfBans } from './chunk-
|
|
5
|
-
import { GROUP_FORMAT, emitEngineEvent, emitWriteEventAfter, createEngineIndex, withOpenIndex, loadDigest, SUGGESTIONS_INDEX_INFIX } from './chunk-
|
|
4
|
+
import { isGroup, invalidSetting, historyFilesOf, buildRecordKey, MIN_KEY_BYTES, resolveSetting, isPerson, acceptedPhrase, removeHistoryFolder, normaliseBan, banListFromInput, validateSetting, withState, packEnvelopeWithChecksum, crc32, openChecksummedEnvelope, SCRAMBLED_ID_BYTES, KEY_FINGERPRINT_LABEL, KEY_FINGERPRINT_BYTES, removeRestoreLeftovers, HISTORY_SWEEP_INTERVAL_MS, SCHEDULE_OFF, parseSchedule, nextMatchAfter, latestMatchAtOrBefore, DAY_MS, listHistoryFolder, historyFileOf, MAX_MANUAL_SUGGESTION_COUNT, MAX_SOURCE_INDEX_NAME_LENGTH, DEFAULT_PREVIEW_LIMIT, MAX_PREVIEW_LIMIT, requireFieldsInSchema, MAX_TIMER_DELAY_MS, BUILD_WRITE_BATCH, BYTES_PER_MIB, MS_PER_SECOND, BUILD_LIST_PAGE, unionOfBans } from './chunk-KOA6T2IC.mjs';
|
|
5
|
+
import { GROUP_FORMAT, emitEngineEvent, emitWriteEventAfter, createEngineIndex, withOpenIndex, loadDigest, SUGGESTIONS_INDEX_INFIX } from './chunk-HSA3H3VW.mjs';
|
|
6
6
|
import { decode } from './chunk-GXCDWLQI.mjs';
|
|
7
|
-
import { spawnNodeWorker, resolveWorkerEntry } from './chunk-
|
|
8
|
-
import { NarsilError, ErrorCodes } from './chunk-
|
|
7
|
+
import { spawnNodeWorker, resolveWorkerEntry } from './chunk-RORNUNXW.mjs';
|
|
8
|
+
import { NarsilError, ErrorCodes } from './chunk-ZKOQR7EA.mjs';
|
|
9
9
|
import { compareCodePoints } from './chunk-TGPKS2UM.mjs';
|
|
10
10
|
|
|
11
11
|
// src/query-suggestions/build-record.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { loadStorageCode, resolvePartialWordAnalysis, resolvePartitionInsertOptions, yieldToEventLoop, createPartitionIndex, writePartitionDocument } from './chunk-
|
|
1
|
+
import { loadStorageCode, resolvePartialWordAnalysis, resolvePartitionInsertOptions, yieldToEventLoop, createPartitionIndex, writePartitionDocument } from './chunk-HSA3H3VW.mjs';
|
|
2
2
|
|
|
3
3
|
// src/partitioning/constants.ts
|
|
4
4
|
var REBALANCE_CHUNK_SIZE = 1e3;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { isSyncEpoch } from './chunk-BUMREPLU.mjs';
|
|
2
|
-
import { requireLoadedMessagePack } from './chunk-
|
|
3
|
-
import { NarsilError, ErrorCodes } from './chunk-
|
|
2
|
+
import { requireLoadedMessagePack } from './chunk-7P5YWDRQ.mjs';
|
|
3
|
+
import { NarsilError, ErrorCodes } from './chunk-ZKOQR7EA.mjs';
|
|
4
4
|
|
|
5
5
|
// src/sync/device/stores/records.ts
|
|
6
6
|
function damaged(detail) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { MAX_HISTORY_FILE_BYTES, openChecksummedEnvelope, KEY_FINGERPRINT_BYTES, DAY_MS, dayFileKey, SCRAMBLED_ID_BYTES, restoreStagingPrefix, resolveSetting, QUERY_HISTORY_ARCHIVE_PREFIX, restoredFileKey, attachedRuntimeOf, MAX_INDEX_UUID_LENGTH, HEADER_SIZE, isGroup, isNormalPhrase, MAX_MAX_LENGTH, MAX_MAX_WORDS, listHistoryFolder, historyFileOf, MIN_PHRASE_TABLE_CAPACITY, PERSON_TABLE_MIN_SLOTS, PAIR_PAGE_BLOCKS, PAIR_BLOCK_SLOTS, packEnvelopeWithChecksum, crc32, MAX_PEOPLE_PER_PHRASE_IN_FILE } from './chunk-
|
|
2
|
-
import { loadSuggestionsCode, emitWriteEventAfter, dropEngineIndex } from './chunk-
|
|
3
|
-
import { NarsilError, ErrorCodes } from './chunk-
|
|
1
|
+
import { MAX_HISTORY_FILE_BYTES, openChecksummedEnvelope, KEY_FINGERPRINT_BYTES, DAY_MS, dayFileKey, SCRAMBLED_ID_BYTES, restoreStagingPrefix, resolveSetting, QUERY_HISTORY_ARCHIVE_PREFIX, restoredFileKey, attachedRuntimeOf, MAX_INDEX_UUID_LENGTH, HEADER_SIZE, isGroup, isNormalPhrase, MAX_MAX_LENGTH, MAX_MAX_WORDS, listHistoryFolder, historyFileOf, MIN_PHRASE_TABLE_CAPACITY, PERSON_TABLE_MIN_SLOTS, PAIR_PAGE_BLOCKS, PAIR_BLOCK_SLOTS, packEnvelopeWithChecksum, crc32, MAX_PEOPLE_PER_PHRASE_IN_FILE } from './chunk-KOA6T2IC.mjs';
|
|
2
|
+
import { loadSuggestionsCode, emitWriteEventAfter, dropEngineIndex } from './chunk-HSA3H3VW.mjs';
|
|
3
|
+
import { NarsilError, ErrorCodes } from './chunk-ZKOQR7EA.mjs';
|
|
4
4
|
|
|
5
5
|
// src/query-suggestions/engine-hooks.ts
|
|
6
6
|
function suggestionIndexesOf(core, sourceName) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { EARLIER_RELEASE_MIN_M, MIN_M, MAX_M } from './chunk-ZXX5GZEX.mjs';
|
|
2
2
|
import { MAX_DOCUMENT_ENCODING_DEPTH, DOCUMENT_REPLY_ENVELOPE_DEPTH, DOCUMENT_ENCODER_RETAINED_BUFFER_BYTES, BYTE_ORDER_MARK_WALK_BYTES_PER_HEADER } from './chunk-4PY4JYMY.mjs';
|
|
3
|
-
import { NarsilError, ErrorCodes } from './chunk-
|
|
3
|
+
import { NarsilError, ErrorCodes } from './chunk-ZKOQR7EA.mjs';
|
|
4
4
|
import { compareCodePoints, holdsUnpairedSurrogate, exceedsCodePoints } from './chunk-TGPKS2UM.mjs';
|
|
5
5
|
|
|
6
6
|
// src/schema/constants.ts
|
|
@@ -867,7 +867,7 @@ var loaded = null;
|
|
|
867
867
|
var loading = null;
|
|
868
868
|
function loadMessagePack() {
|
|
869
869
|
if (loaded !== null) return Promise.resolve(loaded);
|
|
870
|
-
loading ??= import('./msgpack-leaf-
|
|
870
|
+
loading ??= import('./msgpack-leaf-H5ZYW7S7.mjs').then(
|
|
871
871
|
(code) => {
|
|
872
872
|
code.bindMsgpackHost({
|
|
873
873
|
BYTE_ORDER_MARK_WALK_BYTES_PER_HEADER,
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { encodeJson, SYNC_CLOSE_SERVER_ERROR,
|
|
2
|
-
import { answerRefusalOf } from './chunk-
|
|
3
|
-
import { archiveRange } from './chunk-
|
|
4
|
-
import { readRecentMemoryFigures, readMemoryFigures, DEFAULT_RERANK_WINDOW } from './chunk-
|
|
5
|
-
import { collectGarbageBeforeRefusal, collectYoungGenerationBeforeRefusal, reportRefusalAfterCollection, reservedHeapBytes, admitHeapBytes } from './chunk-
|
|
6
|
-
import { MAX_FILTER_DEPTH } from './chunk-
|
|
7
|
-
import { bindSignalStop } from './chunk-
|
|
1
|
+
import { CHANGES_SUBPROTOCOL, SYNC_SUBPROTOCOL, encodeJson, SYNC_CLOSE_SERVER_ERROR, encodeScore } from './chunk-F6F4G322.mjs';
|
|
2
|
+
import { answerRefusalOf } from './chunk-JXINPXRS.mjs';
|
|
3
|
+
import { archiveRange, FEED_SOCKET_MAX_BACKPRESSURE_BYTES, FEED_SOCKET_MAX_PAYLOAD_BYTES } from './chunk-Z6SIJH5O.mjs';
|
|
4
|
+
import { readRecentMemoryFigures, readMemoryFigures, DEFAULT_RERANK_WINDOW } from './chunk-HSA3H3VW.mjs';
|
|
5
|
+
import { collectGarbageBeforeRefusal, collectYoungGenerationBeforeRefusal, reportRefusalAfterCollection, reservedHeapBytes, admitHeapBytes } from './chunk-AOYQTX6W.mjs';
|
|
6
|
+
import { MAX_FILTER_DEPTH } from './chunk-IL5DRCNU.mjs';
|
|
7
|
+
import { bindSignalStop } from './chunk-RORNUNXW.mjs';
|
|
8
8
|
import { HEAP_BLOCK_FRACTION_BELOW_V8_INEFFECTIVE_MARK_COMPACT_LINE } from './chunk-UPDNNOTG.mjs';
|
|
9
9
|
import { ANALYSIS_CHANGE_MEMBERS, MAX_SORT_FIELDS } from './chunk-3ECIRFS5.mjs';
|
|
10
|
-
import { nativeSearchCoreIsEnabled, loadNativeCore } from './chunk-
|
|
11
|
-
import { NarsilError, ServerErrorCodes, ErrorCodes } from './chunk-
|
|
10
|
+
import { nativeSearchCoreIsEnabled, loadNativeCore } from './chunk-ASZLNVWW.mjs';
|
|
11
|
+
import { NarsilError, ServerErrorCodes, ErrorCodes } from './chunk-ZKOQR7EA.mjs';
|
|
12
12
|
import { randomUUID } from 'crypto';
|
|
13
13
|
import { mkdtemp, open, rm } from 'fs/promises';
|
|
14
14
|
import { tmpdir } from 'os';
|
|
@@ -234,6 +234,13 @@ var STATUS_BY_CODE = {
|
|
|
234
234
|
SYNC_NOT_READY: 503,
|
|
235
235
|
SYNC_NOT_ENABLED: 404,
|
|
236
236
|
SYNC_SNAPSHOT_PREPARING: 503,
|
|
237
|
+
CHANGES_DURABILITY_REQUIRED: 409,
|
|
238
|
+
CHANGES_BACKUP_STORE_REQUIRED: 409,
|
|
239
|
+
CHANGES_NOT_READY: 503,
|
|
240
|
+
CHANGES_NOT_ENABLED: 404,
|
|
241
|
+
CHANGES_PREVIOUS_DOCUMENT_REQUIRED: 409,
|
|
242
|
+
CHANGES_EXPORT_PREPARING: 503,
|
|
243
|
+
CHANGES_INVALID_POSITIONS: 400,
|
|
237
244
|
QUERY_SUGGESTIONS_NOT_ENABLED: 404,
|
|
238
245
|
EMBEDDING_FAILED: 503,
|
|
239
246
|
RERANK_FAILED: 503,
|
|
@@ -750,6 +757,20 @@ function respondError(ctx, err) {
|
|
|
750
757
|
const { status, body } = toHttpError(err);
|
|
751
758
|
sendError(ctx.res, status, body.code, body.message, body.details);
|
|
752
759
|
}
|
|
760
|
+
function retryAfterSecondsOf(err, preparingCode) {
|
|
761
|
+
if (!(err instanceof NarsilError) || err.code !== preparingCode) return null;
|
|
762
|
+
const retryAfterMs = err.details?.retryAfterMs;
|
|
763
|
+
return typeof retryAfterMs === "number" && retryAfterMs > 0 ? Math.ceil(retryAfterMs / 1e3) : 1;
|
|
764
|
+
}
|
|
765
|
+
function respondPreparingError(ctx, err, preparingCode) {
|
|
766
|
+
const retryAfterSeconds = retryAfterSecondsOf(err, preparingCode);
|
|
767
|
+
if (retryAfterSeconds === null || ctx.abort.aborted) {
|
|
768
|
+
respondError(ctx, err);
|
|
769
|
+
return;
|
|
770
|
+
}
|
|
771
|
+
const { status, body } = toHttpError(err);
|
|
772
|
+
sendError(ctx.res, status, body.code, body.message, body.details, [["Retry-After", String(retryAfterSeconds)]]);
|
|
773
|
+
}
|
|
753
774
|
function respondJson(ctx, data, status = 200) {
|
|
754
775
|
if (ctx.abort.aborted) return;
|
|
755
776
|
sendJson(ctx.res, data, status, ctx.abort);
|
|
@@ -1788,6 +1809,34 @@ function backupRoutes(shared) {
|
|
|
1788
1809
|
];
|
|
1789
1810
|
}
|
|
1790
1811
|
|
|
1812
|
+
// src/server/routes/changes.ts
|
|
1813
|
+
function changesRoutes(shared) {
|
|
1814
|
+
return [
|
|
1815
|
+
{
|
|
1816
|
+
method: "get",
|
|
1817
|
+
path: "/indexes/:name/changes",
|
|
1818
|
+
handler: "getChanges",
|
|
1819
|
+
options: shared.named,
|
|
1820
|
+
operationId: "getChanges",
|
|
1821
|
+
summary: "Report the change capture setting of an index and its epoch",
|
|
1822
|
+
tags: ["Changes"],
|
|
1823
|
+
request: null,
|
|
1824
|
+
responses: { 200: "ChangesStatus" }
|
|
1825
|
+
},
|
|
1826
|
+
{
|
|
1827
|
+
method: "put",
|
|
1828
|
+
path: "/indexes/:name/changes",
|
|
1829
|
+
handler: "updateChanges",
|
|
1830
|
+
options: shared.namedBody,
|
|
1831
|
+
operationId: "updateChanges",
|
|
1832
|
+
summary: "Replace the change capture setting of an index",
|
|
1833
|
+
tags: ["Changes"],
|
|
1834
|
+
request: "ChangesSetting",
|
|
1835
|
+
responses: { 200: "OkResponse" }
|
|
1836
|
+
}
|
|
1837
|
+
];
|
|
1838
|
+
}
|
|
1839
|
+
|
|
1791
1840
|
// src/server/routes/documents.ts
|
|
1792
1841
|
function documentRoutes(shared) {
|
|
1793
1842
|
const { named, document, writeBody, readBody: readBody2, batchBody, importBody, documentWriteBody } = shared;
|
|
@@ -2654,20 +2703,6 @@ function refuseRange(ctx, length, entityTag) {
|
|
|
2654
2703
|
ctx.res.writeStatus(statusLine(416)).writeHeader("Content-Range", `bytes */${length}`).writeHeader("ETag", `"${entityTag}"`).writeHeader("Cache-Control", "no-store").end();
|
|
2655
2704
|
});
|
|
2656
2705
|
}
|
|
2657
|
-
function retryAfterSecondsOf(err) {
|
|
2658
|
-
if (!(err instanceof NarsilError) || err.code !== ErrorCodes.SYNC_SNAPSHOT_PREPARING) return null;
|
|
2659
|
-
const retryAfterMs = err.details?.retryAfterMs;
|
|
2660
|
-
return typeof retryAfterMs === "number" && retryAfterMs > 0 ? Math.ceil(retryAfterMs / 1e3) : 1;
|
|
2661
|
-
}
|
|
2662
|
-
function refuseSnapshot(ctx, err) {
|
|
2663
|
-
const retryAfterSeconds = retryAfterSecondsOf(err);
|
|
2664
|
-
if (retryAfterSeconds === null || ctx.abort.aborted) {
|
|
2665
|
-
respondError(ctx, err);
|
|
2666
|
-
return;
|
|
2667
|
-
}
|
|
2668
|
-
const { status, body } = toHttpError(err);
|
|
2669
|
-
sendError(ctx.res, status, body.code, body.message, body.details, [["Retry-After", String(retryAfterSeconds)]]);
|
|
2670
|
-
}
|
|
2671
2706
|
function createSyncSnapshotHandler(serving) {
|
|
2672
2707
|
return async (ctx) => {
|
|
2673
2708
|
const sync = serving();
|
|
@@ -2679,7 +2714,7 @@ function createSyncSnapshotHandler(serving) {
|
|
|
2679
2714
|
try {
|
|
2680
2715
|
download = await sync.snapshot(ctx.params[0]);
|
|
2681
2716
|
} catch (err) {
|
|
2682
|
-
|
|
2717
|
+
respondPreparingError(ctx, err, ErrorCodes.SYNC_SNAPSHOT_PREPARING);
|
|
2683
2718
|
return;
|
|
2684
2719
|
}
|
|
2685
2720
|
try {
|
|
@@ -2769,6 +2804,7 @@ function serverRoutes(limits) {
|
|
|
2769
2804
|
...maintenanceRoutes(shared),
|
|
2770
2805
|
...backupRoutes(shared),
|
|
2771
2806
|
...syncRoutes(shared),
|
|
2807
|
+
...changesRoutes(shared),
|
|
2772
2808
|
...querySuggestionRoutes(shared)
|
|
2773
2809
|
];
|
|
2774
2810
|
}
|
|
@@ -2816,21 +2852,14 @@ async function loadUWebSockets() {
|
|
|
2816
2852
|
}
|
|
2817
2853
|
}
|
|
2818
2854
|
|
|
2819
|
-
// src/sync/feed/constants.ts
|
|
2820
|
-
var DEFAULT_FEED_WINDOW_BYTES = 8388608;
|
|
2821
|
-
var ENTRIES_MESSAGE_LIMIT_BYTES = 1048576;
|
|
2822
|
-
var DEFAULT_MAX_FEED_CONNECTIONS = 1e4;
|
|
2823
|
-
var DEFAULT_MAX_FEED_CATCH_UPS = 32;
|
|
2824
|
-
var DEFAULT_MAX_FEED_BUFFERED_BYTES = 268435456;
|
|
2825
|
-
var FEED_HEAD_RETRY_MS = 200;
|
|
2826
|
-
var TIMER_DELAY_LIMIT_MS = 2147483647;
|
|
2827
|
-
var FEED_SOCKET_MAX_PAYLOAD_BYTES = 131072;
|
|
2828
|
-
var FEED_SOCKET_MAX_BACKPRESSURE_BYTES = 1073741824;
|
|
2829
|
-
|
|
2830
2855
|
// src/server/sync/feed-route.ts
|
|
2831
|
-
var
|
|
2832
|
-
|
|
2833
|
-
|
|
2856
|
+
var SYNC_FEED_ROUTE = { path: "/indexes/:name/sync/feed", subprotocol: SYNC_SUBPROTOCOL };
|
|
2857
|
+
var CHANGES_FEED_ROUTE = {
|
|
2858
|
+
path: "/indexes/:name/changes/feed",
|
|
2859
|
+
subprotocol: CHANGES_SUBPROTOCOL
|
|
2860
|
+
};
|
|
2861
|
+
function offersSubprotocol(header, subprotocol) {
|
|
2862
|
+
return header.split(",").some((value) => value.trim() === subprotocol);
|
|
2834
2863
|
}
|
|
2835
2864
|
function indexNameOf(raw) {
|
|
2836
2865
|
if (!raw.includes("%")) return raw;
|
|
@@ -2861,7 +2890,7 @@ function refuse(res, err) {
|
|
|
2861
2890
|
const { status, body } = toHttpError(err);
|
|
2862
2891
|
sendError(res, status, body.code, body.message, body.details);
|
|
2863
2892
|
}
|
|
2864
|
-
async function upgradeFeed(gateway, res, context, indexName, handshake) {
|
|
2893
|
+
async function upgradeFeed(gateway, subprotocol, res, context, indexName, handshake) {
|
|
2865
2894
|
const abort = initAbortHandler(res);
|
|
2866
2895
|
let authorization;
|
|
2867
2896
|
try {
|
|
@@ -2889,11 +2918,12 @@ async function upgradeFeed(gateway, res, context, indexName, handshake) {
|
|
|
2889
2918
|
}
|
|
2890
2919
|
const userData = { ticket, endpoint: null, closed: false };
|
|
2891
2920
|
res.cork(() => {
|
|
2892
|
-
res.upgrade(userData, handshake.key,
|
|
2921
|
+
res.upgrade(userData, handshake.key, subprotocol, handshake.extensions, handshake.socketContext);
|
|
2893
2922
|
});
|
|
2894
2923
|
}
|
|
2895
|
-
function registerFeedRoute(app, gateway) {
|
|
2896
|
-
|
|
2924
|
+
function registerFeedRoute(app, gateway, route) {
|
|
2925
|
+
const { path: path2, subprotocol } = route;
|
|
2926
|
+
app.ws(path2, {
|
|
2897
2927
|
maxPayloadLength: FEED_SOCKET_MAX_PAYLOAD_BYTES,
|
|
2898
2928
|
maxBackpressure: FEED_SOCKET_MAX_BACKPRESSURE_BYTES,
|
|
2899
2929
|
upgrade(res, req, socketContext) {
|
|
@@ -2915,17 +2945,17 @@ function registerFeedRoute(app, gateway) {
|
|
|
2915
2945
|
remoteAddress: Buffer.from(res.getRemoteAddressAsText()).toString()
|
|
2916
2946
|
};
|
|
2917
2947
|
const indexName = indexNameOf(rawName);
|
|
2918
|
-
if (indexName === null || !offersSubprotocol(protocols)) {
|
|
2948
|
+
if (indexName === null || !offersSubprotocol(protocols, subprotocol)) {
|
|
2919
2949
|
res.onAborted(() => void 0);
|
|
2920
2950
|
sendError(
|
|
2921
2951
|
res,
|
|
2922
2952
|
400,
|
|
2923
2953
|
ServerErrorCodes.INVALID_REQUEST,
|
|
2924
|
-
indexName === null ? "A path segment holds a percent-escape the server cannot decode" : `The upgrade must offer the subprotocol ${
|
|
2954
|
+
indexName === null ? "A path segment holds a percent-escape the server cannot decode" : `The upgrade must offer the subprotocol ${subprotocol}`
|
|
2925
2955
|
);
|
|
2926
2956
|
return;
|
|
2927
2957
|
}
|
|
2928
|
-
void upgradeFeed(gateway, res, context, indexName, handshake).catch(() => void 0);
|
|
2958
|
+
void upgradeFeed(gateway, subprotocol, res, context, indexName, handshake).catch(() => void 0);
|
|
2929
2959
|
},
|
|
2930
2960
|
open(ws) {
|
|
2931
2961
|
const data = ws.getUserData();
|
|
@@ -3041,4 +3071,4 @@ async function departureConfirmation(word) {
|
|
|
3041
3071
|
if (waiting.async) await waiting.value;
|
|
3042
3072
|
}
|
|
3043
3073
|
|
|
3044
|
-
export { ASYNC_IMPORT_CAPABILITY, BM25_TUNING_CAPABILITY,
|
|
3074
|
+
export { ASYNC_IMPORT_CAPABILITY, BM25_TUNING_CAPABILITY, CHANGES_FEED_ROUTE, CHANGE_ANALYSIS_CAPABILITY, DEFAULT_IMPORT_BATCH_SIZE, DEFAULT_MAX_BODY_BYTES, DEFAULT_MAX_BODY_BYTES_IN_FLIGHT_FRACTION, DEFAULT_MAX_CONCURRENT_REQUESTS, DEFAULT_MAX_CONCURRENT_TASKS, DEFAULT_MAX_FETCH_DOCUMENTS, DEFAULT_MAX_IMPORT_BYTES, DEFAULT_MAX_IMPORT_ERRORS, DEFAULT_MAX_LINE_BYTES, DEFAULT_MAX_RERANK_WINDOW, DEFAULT_MAX_RESTORE_BYTES, DEFAULT_MAX_RESULT_WINDOW, DEFAULT_MAX_RETAINED_TASKS, DEFAULT_MAX_TASK_PAGE_SIZE, DEFAULT_TASK_PAGE_SIZE, DOCUMENT_EXPORT_CAPABILITY, DOCUMENT_EXPORT_CONTENT_TYPE, IMPORT_FLUSHES_IN_FLIGHT, INDEX_LIFECYCLE_CAPABILITY, INDEX_TOUCH_INTERVALS_PER_IDLE_TIMEOUT, MAIN_THREAD_GATE_SLOT, MAX_BODY_BYTES_IN_FLIGHT_FRACTION, MAX_INDEX_TOUCH_INTERVAL_MS, MAX_LONG_QUERIES_IN_FLIGHT, MIN_COUNTED_SERVER_LIMIT, MIN_UNBOUNDED_SERVER_LIMIT, PROMETHEUS_TEXT_CONTENT_TYPE, REBUILD_ANALYSIS_CAPABILITY, RELAY_STREAM_CHUNKS_IN_FLIGHT, REQUEST_THREAD_CLOSE_AT_EXIT_MS, REQUEST_THREAD_DEPARTURE_DRAIN_MS, REQUEST_THREAD_MOVE_AFTER_MS, RUNNING_TASK_TTL_MS, SEARCH_CLOCK_SAMPLE_UNITS, SERVER_CAPABILITIES, SNAPSHOT_ARCHIVE_CONTENT_TYPE, SYNC_FEED_ROUTE, SYNONYMS_CAPABILITY, TASK_CANCEL_CAPABILITY, TASK_FILTER_CAPABILITY, TASK_PROGRESS_WRITE_INTERVAL_MS, TERMINAL_TASK_TTL_MS, acceptorOf, authorizerFor, awaitDepartureConfirmation, badRequest, bindResponseStop, childAppOf, clearBodyBudgetSlot, clearGateSlot, closeEveryThreadAtExit, closeWhenTheProcessExits, confirmDeparture, corsHeaderReader, createBodyBudgetBuffer, createCloseAtExitWords, createDepartureWord, createDocumentReadHandlers, createRouteRunner, createSharedBodyBudget, createSharedGateBuffer, createSharedRequestGate, createSyncSnapshotHandler, createVersionHandler, departureConfirmation, departureConfirmed, encodeQueryResult, gateSlotOfWorker, httpStatusForNarsilError, isMainFeedNote, isRemoveOnlyBatch, isThreadFeedNote, loadUWebSockets, parseJson, parseJsonOptional, parseRefusalOf, parseTaskListQuery, parseWriteJson, refuseRegex, refusedRegex, registerFeedRoute, registerServerRoutes, rejectInvalid, requestSignal, resolveCors, respondAnswer, respondError, respondJson, respondPreparingError, responseStopOf, sendError, sendRelayed, sendStream, sendText, serializeBatchResult, serializeNarsilError, serverRoutes, statusLine, stopResponse, toHttpError, validateBatch, validateChangeAnalysis, validateCreateIndex, validateDocumentBody, validateQuery, validateRebalance, validateSuggest, versionReport, withServerRerankWindow };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { WORKER_YOUNG_GENERATION_MB } from './chunk-
|
|
1
|
+
import { WORKER_YOUNG_GENERATION_MB } from './chunk-RORNUNXW.mjs';
|
|
2
2
|
import { REFUSAL_YOUNG_COLLECTION_MIN_INTERVAL_MS, collectYoungGeneration, collectAndReturnPages, REFUSAL_COLLECTION_MIN_INTERVAL_MS, REFUSAL_COLLECTION_TIME_MULTIPLE } from './chunk-UPDNNOTG.mjs';
|
|
3
3
|
|
|
4
4
|
// src/workers/resource-limits.ts
|