James
James

Reputation: 11

spring-data - connecting to relational Databases

Researching Spring-Data - I understand why you would use for NoSQL databases but am struggling why you would use Spring-Data for relational databases over the standard Spring-ORM capabilities (e.g. the JPA support as standard).

Anyone got clear use-cases why you would use the spring-data framework for relational queries?

Thanks,

James.

Upvotes: 1

Views: 396

Answers (1)

Oliver Drotbohm
Oliver Drotbohm

Reputation: 83081

The JPA Module of the Spring Data project is different from the NOSQL ones as we don't need to provide a low level store abstraction ourselves. So the main features are:

  • elimination of a large chunk of the implementation code needed for repositories (see this blog post for a showcase)
  • abstractions for pagination and dynamic sorting
  • DDD specifications to allow defining domain predicates (see this blog post as example)
  • support for Querydsl predicates
  • transparent entity auditing

The JDBC module of Spring contains support for Querydsl as well.

Upvotes: 2

Related Questions