spring-projects/spring-data-jpa — pull request #80 by thomasdarimont (2014-04-24 09:20:11+00:00)
Title: DATAJPA-455 - Add support for stored procedure backed repository methods.

First round of support for JPA 2.1 stored procedures mapping for Repository methods. Introduced @Procedure annotation for declaring stored procedure metadata. Repository methods backed by stored procedures are represented as a StoredProcedureJpaQuery that is constructed by JpaQueryFactory#fromProcedureAnnotation. Enhanced JpaQueryLookupStrategy to support @Procedure. Introduced StoredProcedureAttribute to capture the derived configuration for a stored procedure query.

The stored procedure needed for the tests is created via the schema-stored-procedures.sql script that is picked up by the customised datasource definition in infrastructure.xml.

Added new test class UserRepositoryStoredProcedureTests to be able to exclude those tests for OpenJPA. OpenJPA tests don't work with hsqldb 2.x and use hsqldb 1.x instead which doesn't support stored procedures.