A Java 8 library that implements the update feature for a Spring Data REST project when a POST, PATCH, PUT or DELETE method is invoked on a
mappedBy
@ManyToMany
annotated field.
Check the test folder for a fast implementation of the library. Remember to:
- Annotate the
@SpringBootApplication
class with the@EnableHandledBackrelations
annotation; - Implement a
BackrelationHandler
as inCompanyCityBackrelationHandler
test; - Annotate a
@ManyToMany(mappedBy=frontRelationField)
field with a@HandledBackrelation
annotation setting the correctBackrelationHandler
bean type value.