Skip to main content

Questions tagged [jpa]

The Java Persistence API (JPA) is a Java specification for accessing, persisting, and managing data between Java objects/classes and a relational database. It is part of the EJB 3.0 specification and is the industry standard approach for Object to Relational Mapping (ORM).

0 votes
2 answers
204 views

I’m refactoring a microservice project where multiple services share the same domain objects. Over time, these objects have diverged across services, causing inconsistencies. To solve this, I plan to ...
Ryley38's user avatar
  • 111
12 votes
4 answers
3k views

In our current architecture, we have a React frontend communicating with a Rust backend via REST calls. We are considering introducing a PostgreSQL database, and my colleague suggests that we should ...
user avatar
2 votes
2 answers
787 views

For the last few days I'm searching any information about compatibility of JPA and Clean Architecture/DDD. I found next ideas for decoupling application from hibernate. Do not use @ManyToMany or @...
AndyFlight's user avatar
0 votes
3 answers
406 views

Being new to JPA and transaction management, I have a Spring Boot REST API application layered like this: Controller -> Service -> DAO -> DB I want to be agnostic from any ORM and am using ...
DAN's user avatar
  • 9
0 votes
0 answers
157 views

I started using factory methods in JPA Entity classes. But I'm not sure if it's an anti-pattern. If it is , then where do I place them instead ? A similar sample is below @Builder @Entity Class ...
kommradHomer's user avatar
0 votes
1 answer
233 views

I am trying to build a "world" consisting of Fields for simplicity lets say there is a water and town field i created two classes @Entity @Inheritance(strategy = InheritanceType....
Tator's user avatar
  • 103
0 votes
0 answers
586 views

According to Should I use a layer between service and repository for a clean architecture - Spring the Peristance layer is deprecated because the Repository is already an abstraction. UML solution of ...
Adri's user avatar
  • 111
0 votes
1 answer
2k views

I am writing a Spring Boot REST API using JPA, so I have my application layers consisting of controllers services repositories entities models for request, response, DTOs This question is mainly ...
dbnex14's user avatar
  • 119
0 votes
1 answer
564 views

The question is specific to the API notation shown in the screen under the heading Table Name with the comment Joins Multiple Tables. I am using Spring Boot with JPA (Database: RDBMS) I have defined ...
ravibeli's user avatar
  • 103
2 votes
1 answer
3k views

Spring Boot/Java 8/MySQL here. I have a widgets table in my MySQL DB that is modeled by a JPA entity like so: @Entity @Table(name = "widgets") @Data public class Widget { @Column(name = ...
hotmeatballsoup's user avatar
0 votes
3 answers
337 views

I'm working on a project where I need to do CRUD operations on Book and Library objects. Naturally the relationship between Book and Library is Many to One, like so: @Entity @Getter @Setter @...
hfg124g76g1's user avatar
4 votes
3 answers
11k views

In the company I work with, we have a 3-layer architecture in our micro-services and the flow is like this: Repository/DAO (entity) => Service (entity) => Controller (dto) At the Controller ...
Hayi's user avatar
  • 57
-2 votes
1 answer
117 views

I'm looking for design patterns to model (java) objects that are partially stored in a database and partially stored some other external source. In my case the external data is a whole lot of files ...
Johannes Hahn's user avatar
3 votes
1 answer
6k views

In a typical Java Spring Web APP: we have the following layers: Model [DB Models] Repositories [where you have queries to DB] Services [Business service where you have the @Transactional annotation] ...
Youans's user avatar
  • 501
2 votes
3 answers
309 views

I work on a large and old application consisting of a server and a fat client. Part of what the application does is handle a large-ish (a few 100MBs) database of frequently changing data (~a dozen ...
Johannes Hahn's user avatar

15 30 50 per page
1
2 3 4 5