#421 - Elevate R2DBC example to top level project.

Moved r2dbc example to a top-level project. Switched to new Spring Data R2DBC project coordinates.

Original pull request: #422.
This commit is contained in:
Oliver Gierke
2018-10-17 16:57:54 +02:00
committed by Mark Paluch
parent 28dd3d8728
commit d2eb42dad1
10 changed files with 37 additions and 8 deletions

13
r2dbc/example/README.adoc Normal file
View File

@@ -0,0 +1,13 @@
== Spring Data R2DBC basics
This projects shows some sample usage of the work-in-progress R2DBC support for Spring Data.
=== Requirements
- A PostgreSQL database server running on port 5432, a database instance named `postgres` with a user `postgres` and an empty password.
=== Interesting bits to look at
- `InfrastructureConfiguration` - sets up a R2DBC `ConnectionFactory` based on the R2DBC Postgres driver (https://github.com/r2dbc/r2dbc-postgresql[r2dbc-postgresql]), a `DatabaseClient` and a `R2dbcRepositoryFactory` to eventually create a `CustomerRepository`.
- `CustomerRepository` - a standard Spring Data reactive CRUD repository exposing query methods using manually defined queries
- `CustomerRepositoryIntegrationTests` - to initialize the database with some setup SQL and the inserting and reading `Customer` instances.