Skip to content

armgit / TREK

Public Imported from GitHub
0

The most complete open-source travel planner: real-time collaboration, bookings, budgets, packing lists, journals, offline PWA, SSO and an AI-ready MCP server, with planet-wide place search and routing built in.

670 B
Raw Blame
/** The databases TREK can run on. MySQL and MariaDB are out of scope (server/CLAUDE.md). */
export type EngineId = 'sqlite' | 'postgres';

/**
 * Which database this process runs on, as `deriveDb` reads it from
 * `TREK_DB_URL`. The Postgres arm carries what its pool needs, so nothing
 * downstream has to check the URL again.
 */
export type DbEngineSettings = { engine: 'sqlite' } | { engine: 'postgres'; url: string; poolMax: number };

/** The most connections the Postgres pool opens (`TREK_DB_POOL_MAX` is refused above it). */
export const DB_POOL_MAX_CEILING = 100;
/** The pool size when `TREK_DB_POOL_MAX` is unset. */
export const DB_POOL_MAX_DEFAULT = 10;