How to combine ConversionServiceAdapter with BeanUpdate? #3923
Unanswered
puskarpeter
asked this question in
Q&A
Replies: 1 comment
-
|
As far as I understand the Spring
What is the problem in autowiring the mapper interface? You don't need to auto wire the generated mapper, just the defined mapper. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am using
mapstruct-spring-extensionsand it is very convenient having to autowire only the generatedConversionServiceAdapterin my services. But I did not find in the tutorial how to combine theBeanUpdatemechanism with this.Use-case: I want to have new method that would handle the mapping with ignored null fields when writing update methods for
PATCHrequests.Is it even possible to achieve this? I assume I could autowire the generated mapper directly in the service with the method but I guess that kind of defeats the purpose of using
ConversionServiceAdapterand having loose coupling. Am I missing something? Appreciate your insights and hopefully you can steer me in the right direction.Beta Was this translation helpful? Give feedback.
All reactions