What problem does it solve?
This Skill provides clear, actionable guidelines to ensure consistent and maintainable JPA entity mapping, preventing common pitfalls and promoting best practices in database interactions.
Core Features & Use Cases
- Entity Mapping Standards: Defines rules for extending base entities, enum mapping, and association policies.
- Fetch Strategy Guidance: Recommends
LAZY fetching and provides solutions for lazy loading issues.
- Locking Strategies: Explains optimistic and pessimistic locking with examples.
- Use Case: When developing new entities, developers can consult this Skill to ensure they adhere to the project's established patterns for auditing, associations, and fetching, leading to more predictable and performant data access.
Quick Start
Follow the jpa-rules skill to ensure your new entity correctly extends BaseEntity and uses LAZY fetching for all associations.