Java demo app illustrating usage of various Spring, JPA and Hibernate features:
- @EntityGraph - EAGER loading of selected attributes (ClientRepository)
- JPA auditing - automatic insertion of useful entity stuff (AuditableEntity)
- @PrePersist - adds new behavior to Entity before save happens (AuditableEntity)
- @Where - allows soft deletes and other permanent filtering of entities (Client)
- @Formula - Hibernate computes virtual read-only column value using given expression (Client)
- @OrderColumn - allows preserving collection order even after save/load (Wishlist)
- Spring Data REST - automatic exposure of Spring Data repositories via REST API (spring-boot-starter-data-rest dependency)
- @RepositoryRestController - enhances Spring Data REST API by custom behavior (ClientController)
Project uses H2 database (can be switched to dedicated MySQL) initialized with sample data.
Useful runtime URLs: