DatabaseAdapterOptions narrowed for the Drizzle arm: the
configured instance and the table registry are both required.
drizzleInstance: DrizzleDatabaseIdentity
The opaque configuration returned by
createDrizzleDatabase(database, transactionBridge). Required.
dialect: SqlJsonDialect
The SQL dialect, used only to translate a nested JSON filter path
(field: ['profile', 'city']). No two dialects spell JSON extraction
alike: PostgreSQL uses #>>, MySQL JSON_UNQUOTE(JSON_EXTRACT(...)) and
SQLite json_extract.
Absent, the adapter reads the dialect off the Drizzle instance, which covers every instance Drizzle ships. Set it when that detection cannot name the dialect — a nested-path filter is then refused by name rather than emitted in a guessed syntax that would return wrong rows.
drizzleTables: Record<string, unknown>
Entity name → real Drizzle table definition. Required, and must hold at least one entry.
entities: Readonly<Record<string, DrizzleCompositeKeyOptions>>
Per-entity overrides keyed by the entity name passed to
IRepository.getRepository.
The only override exercised today is primaryKey, which replaces the
hardcoded 'id' column the adapter reads when building findById/
update/delete predicates. An absent entry falls back to ['id'],
preserving the prior behaviour (including its refuse-by-name when id is
missing from the table).
poolStats: () => DatabasePoolCapacity
Application-owned callback reporting the driver's connection-pool
counters (M90b). The application reads its own driver's documented pool
API — the configured Drizzle identity is opaque to this package — and
the adapter publishes the returned DatabasePoolCapacity
snapshot to the database health indicator through an internal seam.
Omitted, the indicator carries no capacity fields. No threshold is applied: saturation is data, not policy.