diff --git a/server/db_backend.ts b/server/db_backend.ts index d1d01304..4111bafa 100644 --- a/server/db_backend.ts +++ b/server/db_backend.ts @@ -5,16 +5,16 @@ import { path } from "./deps.ts"; /** * Environment variables: - * - SB_DB_BACKEND: "denokv" or "memory" (default: denokv) - * - SB_KV_DB (denokv only): path to the database file (default .silverbullet.db) + * - SB_DB_BACKEND: "kv" or "memory" (default: kv) + * - SB_KV_DB (kv only): path to the database file (default .silverbullet.db) */ export async function determineDatabaseBackend( singleTenantFolder?: string, ): Promise { - const backendConfig = Deno.env.get("SB_DB_BACKEND") || "denokv"; + const backendConfig = Deno.env.get("SB_DB_BACKEND") || "kv"; switch (backendConfig) { - case "denokv": { + case "kv": { let dbFile: string | undefined = Deno.env.get("SB_KV_DB") || ".silverbullet.db"; @@ -28,7 +28,7 @@ export async function determineDatabaseBackend( } const denoDb = await Deno.openKv(dbFile); console.info( - `Using DenoKV as a database backend (${dbFile || "cloud"}).`, + `Using KV as a database backend (${dbFile || "cloud"}).`, ); return new DenoKvPrimitives(denoDb); } diff --git a/website/Install/Configuration.md b/website/Install/Configuration.md index b7717c96..7095d2eb 100644 --- a/website/Install/Configuration.md +++ b/website/Install/Configuration.md @@ -69,7 +69,7 @@ When self-hosting SilverBullet (that is, on any server other than on [[Install/D KV can be configured as follows: -* `SB_DB_BACKEND`: `denokv` (default, so can be omitted) +* `SB_DB_BACKEND`: `kv` (default, so can be omitted) * `SB_KV_DB`: path to the file name of the (SQLite) database to store data in, defaults to `.silverbullet.db` in the space’s folder (when kept on disk). When SilverBullet runs on [[Install/Deno Deploy]] it automatically uses its cloud implementation of KV.