Class: DatabaseModule
Global module that provides database connectivity for the application.
Description
This module is responsible for:
- Setting up and managing the PostgreSQL connection pool
- Providing the Drizzle ORM service for database operations
- Making database services available globally throughout the application
The module is configurable through the forRoot() method inherited from ConfigurableDatabaseModule.
Example
// In your app.module.ts
@Module({
imports: [
DatabaseModule.forRoot({
host: 'localhost',
port: 5432,
user: 'postgres',
password: 'secret',
database: 'expensify'
})
]
})
export class AppModule {}
Extends
Constructors
new DatabaseModule()
new DatabaseModule():
DatabaseModule
Returns
Inherited from
ConfigurableDatabaseModule.constructor