- Benefits of Using spring data
Reduces boilerplate code
Example: traditional JDBM connnector
1 | public Room getRoomJDBC() throws Exception{ |
Instead, with Spring Data, it could be just one line of code:
1 | public Room getRoomSpringData(){ |
reduce a lots of code and time, and reduce the posibility of making error when
writing the 20 lines of code.
Providing ability to swap out datasources much easier
Always focus on the business logic, not on the data access code.