MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / createSelfHostDb

Function createSelfHostDb

apps/host-selfhost/src/db/self-host-db.ts:155–161  ·  view source on GitHub ↗
(options: SelfHostDbLayerOptions)

Source from the content-addressed store, hash-verified

153 * Auth can open its own libSQL connection to the same `file:` URL).
154 */
155export const createSelfHostDb = (options: SelfHostDbLayerOptions): Promise<SelfHostDbHandle> =>
156 createSqliteExecutorDb({
157 tables: collectTables(),
158 namespace: options.namespace ?? SELF_HOST_NAMESPACE,
159 version: options.version ?? SELF_HOST_SCHEMA_VERSION,
160 path: options.path,
161 });
162
163// Shared DbProvider seam (P2a). The self-host handle keeps its libSQL driver,
164// WAL/busy_timeout PRAGMAs, and the idempotent

Callers 5

addOrgIntegrationFunction · 0.90
makeSelfHostAppFunction · 0.90
makeSelfHostTestAppFunction · 0.90

Calls 2

createSqliteExecutorDbFunction · 0.85
collectTablesFunction · 0.85

Tested by 1

addOrgIntegrationFunction · 0.72