Our great sponsors
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
The rest of this might end up sounding like a rant against Spring Data JPA. For what you're doing, you need to be very aware of what's happening in the entity manager. Spring Data JPA is hiding the entity manager from you, so you have to know how a JPA repository is actually implemented to have an idea of what is going on. Your CRUD repository is going to be an instance of SimpleJpaRepository, so you can reference the Spring Data JPA source code to understand what is going on. Personally, this is exactly why I wouldn't use Spring Data JPA and its automagical CRUD repositories. Writing correct JPA code is hard enough, and if you don't know what the entity manager is doing, you will have a bad time. Spring Data JPA hiding things seems counterproductive to using JPA. Anyways...
Related posts
- How to write a native query in spring boot jpa(postgres) which has "where in" check on composite columns?
- What does @Transactional keep you from needing to call .save()?
- Multiple Datasources in an application
- QueryDSL and/or CriteriaAPI with multi-Joins on properties to Sort, Filter and Paging not working
- From PHP to Java