Ask Your Question
2

What problem are encountered while updating an Entity that was converted from DTO using ModelMapper in a Spring Boot Service?

asked 2021-04-17 11:00:00 +0000

scrum gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2021-12-09 22:00:00 +0000

devzero gravatar image

One potential problem that could be encountered when updating an Entity that was converted from a DTO using ModelMapper in a Spring Boot Service is that any changes made to the original DTO after it was converted may not be reflected in the Entity. This is because the ModelMapper only maps values from the DTO to the Entity during the initial conversion, and does not track any subsequent changes to the DTO properties. Therefore, any updates to the DTO properties must be explicitly applied to the corresponding Entity properties before saving the Entity to the database.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2021-04-17 11:00:00 +0000

Seen: 10 times

Last updated: Dec 09 '21