Kotlin Exposed ORM Patterns

•
156k
•

Simplifies database access in Kotlin using JetBrains Exposed with ready-to-use patterns for DSL, DAO, and migrations.

This skill provides a comprehensive library of design patterns and implementation guides for JetBrains Exposed, the lightweight SQL library for Kotlin. It covers the full database lifecycle, from configuring HikariCP connection pooling and Flyway migrations to implementing complex DSL queries and the DAO (Data Access Object) pattern. By providing standardized templates for table definitions, batch operations, and pagination, this skill ensures type-safe database operations, efficient transaction handling with coroutines, and clean repository architectures that decouple business logic from the data layer.

Key Features

01Standardized repository pattern for clean architecture
02DSL and DAO query patterns for type-safe database access
03Coroutine-safe transaction handling via newSuspendedTransaction
04Production-ready HikariCP connection pool configuration
05156,032 GitHub stars
06Automated schema management with Flyway migrations

Use Cases

01Setting up a new Kotlin backend with PostgreSQL or H2 databases
02Implementing complex table relationships and join queries
03Refactoring raw SQL queries into type-safe Exposed DSL code