Commit Graph

185 Commits

Author SHA1 Message Date
Mark Paluch
97ef1ed8b7 #244 - Add Reactor Checkpoint operator for SQL execution.
We now integrate with Reactor's checkpoint operator to include more information for debugging.
2019-12-02 11:12:59 +01:00
Mark Paluch
86ce98d08d #243 - Polishing.
Add author tags. Extend test. Reformat code.
2019-12-02 08:56:57 +01:00
Ferdinand Jacobs
38bbd4838e #243 - Add unit test for rowsUpdated.
rowsUpdated should always emit a single value.
2019-12-02 08:56:54 +01:00
Jens Schauder
887f0ae289 #237 - Polishing.
Removed superfluous package name from `@Query` usage.

Original pull request: #238.
2019-11-28 14:42:09 +01:00
Mark Paluch
ecc0fca306 #237 - Move @Query annotation to o.s.d.r2dbc.repository.
Original pull request: #238.
2019-11-28 14:41:57 +01:00
Jens Schauder
d442fca38d #235 - Polishing.
Added test and tweaked documentation to clarify that other numeric types beyond `Integer` are admissible.
Split a test in order to have meaningful test names.

Original pull request: #238.
2019-11-28 14:41:34 +01:00
Mark Paluch
6d37fde4c7 #235 - Add Modifying query annotation.
We now support returning the affected rows count for repository query methods that are annotated with the Modifying annotation. A modifying query method can return either the affected row count, a boolean value whether at least one row was updated or suppress value emission.

    @Query("UPDATE person SET firstname = :firstname where lastname = :lastname")
    Mono<Integer> setFixedFirstnameFor(String firstname, String lastname);

Original pull request: #238.
2019-11-28 14:33:38 +01:00
Mark Paluch
4801a4fbc2 #232 - Guard Repository.save(…) with provided Id with TransientDataAccessException if row does not exist.
We now emit a TransientDataAccessException if an object with a provided Id yields no affected rows. Such an arrangement is typically an indicator for a bug where calling code expects the object to be inserted with a provided Id.
2019-11-28 10:17:20 +01:00
Mark Paluch
cb1784f632 #239 - Add documentation for projecting repository query methods. 2019-11-22 15:36:22 +01:00
Mark Paluch
b5db108c7a #204 - Polishing.
Fix unwrapping in CloseSuppressingInvocationHandler. Remove unused conditional branches.
2019-10-24 10:12:07 +02:00
Mark Paluch
b5ac43bd20 #204 - Add SingleConnectionConnectionFactory. 2019-10-24 10:11:10 +02:00
Mark Paluch
94c8f751a7 #212 - Polishing.
Consistently apply summing of updated rows. Tweak copyright years in license header to reflect file inception year.

Original pull request: #213.
2019-10-23 14:01:30 +02:00
pull-vert
2fac62a38c #212 - Provide Kotlin Coroutine extensions on UpdatedRowsFetchSpec.
Original pull request: #213.
2019-10-23 14:01:30 +02:00
Mark Paluch
c77534fa58 #216 - Fix subscription in ConnectionFactoryInitializer.execute(…).
ConnectionFactoryInitializer.execute(…) now calls .block() to subscribe to database initializer and database cleaner.

Previously, the resulting Mono wasn't subscribed to and the database was not initialized.
2019-10-20 14:11:04 +02:00
Mark Paluch
96de5d74a6 #209 - Polishing.
Update ticket reference in test.

Original pull request: #210.
2019-10-15 16:46:12 +02:00
Ibanga Enoobong Ime
bd2cc60480 #209 - Provide extensions on TypedExecuteSpec and GenericExecuteSpec.
The original extensions did not allow for executing fetch operations because they where on BindSpec.

Original pull request: #210.
2019-10-15 16:46:04 +02:00
Mark Paluch
6f27bb7b58 #154 - Polishing. 2019-10-01 12:24:12 +02:00
Mark Paluch
6d52ac7ff7 #154 - Prepare 1.0 RC1. 2019-10-01 12:07:58 +02:00
Mark Paluch
c3aadd6689 #154 - Updated changelog. 2019-10-01 12:07:58 +02:00
Mark Paluch
fbb3f3ac69 #199 - Add documentation for Connection Factory Initialization. 2019-09-30 15:15:44 +02:00
Mark Paluch
53121b49a4 #199 - Add documentation for Kotlin support. 2019-09-30 15:15:44 +02:00
Sébastien Deleuze
35b0fec05a #200 - Remove @ExperimentalCoroutinesApi annotations. 2019-09-30 14:57:48 +02:00
Mark Paluch
a67db9f88a #107 - Polishing.
Adapt tests to changed behavior of TransactionalOperator.
2019-09-28 15:35:26 +02:00
Mark Paluch
fd66f8af26 #178 - Consider named and indexed parameters for named parameter processing.
Named parameters can be provided by name and by index. Repository query methods bind parameters by name if a named parameter can be found.

If parameters are bound by index, then the parameter name is looked up by index (index corresponds with the order of parameter name discovery when parsing the query). and bound to the parameter.
2019-09-20 15:50:36 +02:00
Mark Paluch
be28752ca6 #190 - Adapt to R2DBC SPI changes. 2019-09-20 15:47:02 +02:00
Mark Paluch
2668ecb702 #185 - Re-enable Postgres integration tests. 2019-09-17 16:21:03 +02:00
Mark Paluch
7362b45156 #188 - Adapt to package changes in r2dbc-mysql. 2019-09-14 21:37:19 +02:00
Mark Paluch
cefd3fc527 #185 - Re-enable Postgres integration tests. 2019-09-13 17:22:21 +02:00
Mark Paluch
d63ad3f56a #186 - Polishing.
Include R2DBC MySQL in driver documentation.
2019-09-13 14:35:11 +02:00
Mark Paluch
1096838dec #186 - Consider byte[] binary data when mapping entities.
We now exclude byte[] properties from being mapped to array types. To map data to a 1-dimensional BYTE[] Postgres type, properties can be declared as Collection<Byte> or Byte[].
2019-09-13 14:34:00 +02:00
Mark Paluch
ba7882ba7b #177 - Polishing.
Add this. for field access.
2019-09-11 16:41:55 +02:00
Mark Paluch
63310031cb #177 - Add tests for NOT IN. 2019-09-11 16:41:37 +02:00
Mark Paluch
353a7e7037 #184 - Polishing.
Disable MySQL SSL to avoid warning logging.
2019-09-11 16:10:22 +02:00
Mark Paluch
ddef57af63 #184 - Restore AutoCommit and IsolationLevel after transaction. 2019-09-11 16:05:58 +02:00
Mark Paluch
62656668ea #185 - Disable Postgres integration tests.
Disabling until r2dbc/r2dbc-postgresql#151 is resolved.
2019-09-11 16:05:41 +02:00
Mark Paluch
fa64006441 #183 - Use Statement.bind(String) and Row.get(String) methods instead of bind(Object). 2019-09-11 15:38:38 +02:00
Mark Paluch
f7b3e96238 #182 - Build against R2DBC 0.8 snapshots.
Disable JAsync tests until JAsync catches up with R2DBC SPI 0.8.
2019-09-11 15:38:21 +02:00
Mark Paluch
084273f026 #161 - Polishing.
Properly convert null arrays to the corresponding, driver-supported array type.
2019-09-05 15:12:28 +02:00
Mark Paluch
611b73149b #161 - Properly convert arrays for Postgres.
We now properly convert array values (single- and multi-dimensional) when inserting rows with arrays.
2019-09-05 15:01:10 +02:00
Mark Paluch
b575e15dd6 #175 - Polishing. 2019-09-05 12:08:06 +02:00
Jay Bryant
a4b7e57bd5 #175 - Editing pass for the reference docs.
Edited the reference guide, checking for spelling, grammar, usage, punctuation, and corporate voice.
2019-09-05 12:08:06 +02:00
Sebastien Deleuze
9064b04110 #172 - Upgrade to Coroutines 1.3.0.
Original pull request: #173.
2019-09-04 11:55:42 +02:00
Mark Paluch
b1dcb38ad8 #170 - Migrate off deprecated Mono/Flux.usingWhen methods. 2019-09-03 17:31:44 +02:00
Mark Paluch
af52bc1a53 #169 - Polishing.
Move R2dbcMappingContextUnitTests to correct source folder.
2019-09-03 16:27:12 +02:00
Mark Paluch
30c5e2f5e0 #162 - Refine declaration of nullable values in DatabaseClient.
DatabaseClient.BindSpec.bind(…) (execute) and DatabaseClient.GenericInsertSpec.value(…) (insert) now consistently accept SettableValue for scalar and absent values.

This change allows us to provide a Kotlin extension leveraging reified generics to provide the type of a value even if it is null to construct an appropriate SettableValue for fluent API usage.
2019-09-03 16:23:48 +02:00
Mark Paluch
bac5c343b7 #169 - Allow usage of Entity-level converters.
We now support Converters on Entity-level if object materialization/dematerialization is handled by application code. We're using a custom R2DBC MappingContext to create mapping metadata for types that have custom converters registered.
2019-09-03 14:25:02 +02:00
Mark Paluch
501d4475e3 #159 - Polishing.
Update tests to work around known issues in type conversion and transaction synchronization.
2019-09-03 12:39:56 +02:00
Mark Paluch
bc9627e987 #159 - Skip result conversion for query methods returning Void. 2019-09-03 12:18:44 +02:00
Jens Schauder
928ac09882 #151 - SimpleR2dbcRepository is now transactional.
Original pull request: #152.
2019-09-03 12:05:32 +02:00
Mark Paluch
ec8f540ed9 #166 - Polishing.
Consider Dialect-specific converters also in DatabaseClient.create(…) factory. Reduce constant visibility. Add tests. Reformat code.

Original pull request: #168.
2019-09-03 11:59:39 +02:00