Graphorin API reference v0.12.1
Graphorin API reference / @graphorin/store-sqlite / connection / OpenConnectionOptions
Interface: OpenConnectionOptions
Defined in: packages/store-sqlite/src/connection.ts:79
Options for openConnection.
Stable
Properties
| Property | Modifier | Type | Description | Defined in |
|---|---|---|---|---|
busyTimeoutMs? | readonly | number | W-067: how long the driver's busy handler waits for a contended write lock before the operation fails with SqliteBusyError. Applied AFTER the hardening pragmas so the exported WAL_HARDENING_PRAGMAS constant keeps its documented bytes; also honoured on the disableWalHardening / :memory: branch. Default 5000 | packages/store-sqlite/src/connection.ts:138 |
cipherLoader? | readonly | () => Promise<BetterSqlite3Constructor> | Internal Optional cipher-driver loader override. When encryption.enabled is true and the operator does not pass driver, this loader is consulted instead of the canonical loadCipherDriver. Used by the test suite to simulate a missing cipher peer without uninstalling the package from the workspace. | packages/store-sqlite/src/connection.ts:129 |
disableWalHardening? | readonly | boolean | If true, do not apply the WAL hardening pragmas. The runner still applies foreign_keys=ON and busy_timeout so the migration step works against :memory: databases. Off by default. | packages/store-sqlite/src/connection.ts:118 |
driver? | readonly | BetterSqlite3Constructor | Override the constructor used to open the underlying database. Used by the test suite to inject a stub. When unset the connection lazily loads better-sqlite3 (or the cipher peer when encryption is enabled) at first call. | packages/store-sqlite/src/connection.ts:107 |
encryption? | readonly | EncryptionConfig | Optional encryption-at-rest configuration. Default: disabled. | packages/store-sqlite/src/connection.ts:82 |
loadVecExtension? | readonly | (db) => void | Override the sqlite-vec load(db) helper. Used by the test suite to verify the loader is invoked without a native build. | packages/store-sqlite/src/connection.ts:112 |
onMissingSqliteVec? | readonly | "linear-fallback" | "fail" | Wave-D D5 (item 10 step 3): policy when the sqlite-vec peer is missing or fails to load. 'fail' (default) rethrows SqliteVecMissingError - the pre-wave behaviour. 'linear-fallback' degrades instead of dying: vector sidecars are kept in PLAIN tables (same names/columns) and KNN runs as an in-process batched cosine scan with setImmediate yields. Suits environments where the native build is unavailable and degraded vector recall beats a crash. A database must stay in ONE mode: the table manager refuses to open vec0 tables in fallback mode (and plain fallback tables in vec0 mode) with an actionable error. | packages/store-sqlite/src/connection.ts:100 |
path | readonly | string | - | packages/store-sqlite/src/connection.ts:80 |
skipSqliteVec? | readonly | boolean | If true, skip loading the sqlite-vec extension. Used by tests that exercise the migration runner without the vector adapter. | packages/store-sqlite/src/connection.ts:87 |