kotlin-exposed-patterns

Implement Kotlin Exposed ORM patterns for DSL queries, DAO usage, and transactions.

1|Updated Apr 7, 2026
One-click install
npx skills add https://github.com/TruCol270/salty-pickle --skill kotlin-exposed-patterns-trucol270
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: kotlin-exposed-patterns
Source: https://github.com/TruCol270/salty-pickle/tree/main/.claude-skills/kotlin-exposed-patterns
Command: npx skills add https://github.com/TruCol270/salty-pickle --skill kotlin-exposed-patterns-trucol270

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Standardizes the use of JetBrains Exposed ORM in Kotlin projects, helping teams implement consistent and maintainable data access layers.

Core Features & Use Cases

  • DSL Queries: Build type-safe SQL with Exposed DSL for readable, expressive data access.
  • DAO Pattern & Transactions: Manage entity lifecycles with DAO and transactional blocks to ensure correctness.
  • Production-ready Config: Integrate HikariCP pooling, Flyway migrations, and repository patterns for scalable apps.
  • Use Case: When starting a new Kotlin service, scaffold a clean Exposed-based data layer that supports migrations, tests, and repo interfaces.

Quick Start

Create a Kotlin project and implement a minimal Exposed-based data layer with a sample DAO and a transactional operation.

Frequently Asked Questions about kotlin-exposed-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What's the best way to structure Kotlin Exposed ORM database access in a production app?

To implement the repository pattern with Kotlin Exposed, wrap DSL queries and DAO entity lifecycles inside transactional blocks. This encapsulates database operations behind repository interfaces, ensuring transactional correctness and standardized data access across projects.

How do I manage transactions correctly when using Exposed ORM?

To manage transactions correctly with Exposed ORM, wrap your DSL queries and DAO operations inside transactional blocks. This ensures entity lifecycle correctness and maintains data integrity during database interactions across your application.

Can I integrate connection pooling and migrations with Kotlin Exposed?

Yes, you can integrate connection pooling and migrations with Kotlin Exposed. Production-ready configuration supports HikariCP for connection pooling and Flyway for database migrations, ensuring scalable and reliable data access setup.

When should I use DSL queries instead of the DAO pattern in Exposed?

Use DSL queries instead of the DAO pattern in Exposed when you need type-safe, expressive SQL for readable data access. Choose DAO when you need to manage entity lifecycles and state within transactional blocks.

How do I scaffold a clean data layer for a new Kotlin service using Exposed?

To scaffold a clean data layer for a new Kotlin service using Exposed, implement repository interfaces with DSL queries and DAO patterns. Include HikariCP connection pooling and Flyway migrations to support tests and scalable operations.