Files
spring-data-examples/jpa/showcase/demo.txt
Oliver Gierke 0ddb2ba0d6 Added showcase for JDK 8's Optional support on repository methods.
Abbreviated JPA sample module folder names. Renamed the Java 8 auditing sample module to Java 8 module as it not only contains samples for auditing anymore.
2014-04-22 14:48:00 +02:00

62 lines
1.6 KiB
Plaintext

1. Introduction
---------------
- Project structure
- Spring configuration
- Services
- Test cases
2. Issues
---------
- Generics, simple queries, pagination (no metadata), is new?, arbitrary queries
- Approach: step by step refactoring -> introduce Spring Data JPA
5. AccountRepository
--------------------
- replace save(…)
- findByCustomer -> show log -> method created from method name
- explain proxy mechanism, method signature possibilities (@Param, return types)
4. Explain general proxy mechanism, SimpleJpaRepository
-------------------------------------------------
- show JpaRepository interface
- findAll(Pageable pageble)
3. CustomerRepository
---------------------
- add dependency to CustomerServiceImpl
- replace findById, findAll, save
- run test
- explain extended method signature possibilities (Pageable, Sort)
- replace findByLastname(Pageable pageable) in CustomerService
6. First summary
----------------
- implementation got obsolete
- switch to after package
7. Querydsl / Specifications
----------------------------
- Introduce Querydsl
- Show Maven setup
- Show predicates
- Integrate test case
7. Custom implementation
------------------------
- copy interface and implementation (hint to visibility)
- adapt AccountRepository
- copy test case
- explain implementation class lookup
8. JDBC implementation (optional)
-----------------------
- copy implementation -> configuration necessary
- copy XML
- run tests -> fail (shows that JDBc bean is used)
- fix SQL by adding FROM -> tests run again
9. Auditing (optional)
-----------------------
- show auditing test from Hades sample project
10. Back to slide deck