Leonard AnghelJan 5, 20201 min readAvoid Fetching Entity In DTO Via Constructor Expression (No Associations)Motivation: You should avoid fetching an entity in DTO via constructor expression to avoid potential N+1 issues. Description: Let's...
Leonard AnghelJan 5, 20201 min readHow To Add An Entity Inside A Spring Projection (No Associations)Motivation: You need to fetch an entity because you plan to modify it. But, you need it next to other read-only data in a Spring...
Leonard AnghelJan 5, 20201 min readHow To Use JPA GenerationType.AUTO And UUID IdentifiersMotivation: Commonly, UUID are used in clustered environment, where numerical primary keys are prone to conflicts. But, for avoiding...