@davoodmehraban89 / VELYQOR / commits / 243bc86
Fork 0

Intelligence, Advanced Charting & Trading Platform

docs: lock PostgreSQL provider portability decision

davoodmehraban89 committed Oct 5, 2026 at 09:52 UTC 243bc8635909e8a71f3c3efd2a41b738a42825e4
1 file changed +20
docs/architecture/ADR-0002-postgresql-provider-portability.md new
+20
@@ -0,0 +1,20 @@
1 +# ADR-0002: PostgreSQL Provider Portability
2 +
3 +Status: Accepted
4 +Date: 2026-10-05
5 +
6 +## Decision
7 +VELYQOR's canonical database technology is PostgreSQL. Hosting provider identity is infrastructure configuration, not a domain dependency.
8 +
9 +The application consumes a standard `DATABASE_URL`. Schema migrations must use portable PostgreSQL features unless an extension is separately approved by ADR. Provider SDKs must not leak into market-domain modules.
10 +
11 +The initial managed provider may be Neon. Supabase, self-hosted PostgreSQL, or another compatible managed service can replace it without redesigning the market domain.
12 +
13 +Cloudflare Hyperdrive may pool/accelerate PostgreSQL connections after a database exists; Hyperdrive is not the datastore itself.
14 +
15 +## Consequences
16 +- No Supabase-specific schema requirement.
17 +- Auth is decoupled from core market data.
18 +- Database migrations live in `db/migrations`.
19 +- Secrets are supplied by runtime configuration and never committed.
20 +- Provider migration remains operational rather than architectural work.