spring-data-relational
spring-data-relational copied to clipboard
Deduplicate code in QueryMapper
Both the JDBC and the R2DBC module have a QueryMapper and a lot of code is duplicated between them. \
We should remove that code duplication, possibly by introducing a common super class.
@schauder
In the case of QueryMapper, I would like to comment on commonization.
QueryMapper is It has two properties: jdbc and r2dbc.
Write the common logic by abstracting it into the “spring-data-relational” module.
There are implementations of each jdbc and r2dbc.
In reality, I refer to the implementation for each property, but I think it would be better to improve maintainability by looking at the common implementation class.
What do you think?
- AbstractQueryMapper.class (module: spring-data-relational)
- JdbcQueryMapper.class (module: spring-data-jdbc)
- R2dbcQueryMapper.class (module: spring-data-r2dbc)