https://github.com/r2dbc/r2dbc-client
Reactive Relational Database Connectivity
https://github.com/r2dbc/r2dbc-client
api database java reactive reactive-streams reactor
Last synced: 9 months ago
JSON representation
Reactive Relational Database Connectivity
- Host: GitHub
- URL: https://github.com/r2dbc/r2dbc-client
- Owner: r2dbc
- License: apache-2.0
- Archived: true
- Created: 2018-01-04T16:48:19.000Z (about 8 years ago)
- Default Branch: main
- Last Pushed: 2020-06-24T09:27:11.000Z (over 5 years ago)
- Last Synced: 2024-08-01T21:49:02.903Z (over 1 year ago)
- Topics: api, database, java, reactive, reactive-streams, reactor
- Language: Java
- Homepage:
- Size: 744 KB
- Stars: 346
- Watchers: 32
- Forks: 24
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG
- License: LICENSE
Awesome Lists containing this project
README
This project is no longer being actively maintained.
# Reactive Relational Database Connectivity Client (Archived)
This project is an exploration of what a Java API for relational database access with [Reactive Streams][rs] might look like. It uses [Project Reactor][pr]. It uses [Jdbi][jd] as an inspiration.
[jd]: http://jdbi.org
[pr]: https://projectreactor.io
[rs]: https://www.reactive-streams.org
## Examples
A quick example of configuration and execution would look like:
```java
PostgresqlConnectionConfiguration configuration = PostgresqlConnectionConfiguration.builder()
.host("")
.database("")
.username("")
.password("")
.build();
R2dbc r2dbc = new R2dbc(new PostgresqlConnectionFactory(configuration));
r2dbc.inTransaction(handle ->
handle.execute("INSERT INTO test VALUES ($1)", 100))
.thenMany(r2dbc.inTransaction(handle ->
handle.select("SELECT value FROM test")
.mapResult(result -> result.map((row, rowMetadata) -> row.get("value", Integer.class)))))
.subscribe(System.out::println);
```
## Maven
Both milestone and snapshot artifacts (library, source, and javadoc) can be found in Maven repositories.
```xml
io.r2dbc
r2dbc-client
0.8.0.RC1
```
Artifacts can bound found at the following repositories.
### Repositories
```xml
spring-snapshots
Spring Snapshots
https://repo.spring.io/snapshot
true
```
```xml
spring-milestones
Spring Milestones
https://repo.spring.io/milestone
false
```
## License
This project is released under version 2.0 of the [Apache License][l].
[l]: https://www.apache.org/licenses/LICENSE-2.0