oracle / oracle-r2dbc

R2DBC Driver for Oracle Database
https://oracle.com
Other
201 stars 42 forks source link

Updates for Release 1.3.0 #157

Closed Michael-A-McMahon closed 2 weeks ago

Michael-A-McMahon commented 3 weeks ago

This branch includes all changes for a 1.3.0 release of Oracle R2DBC.

I have verified this branch by running our test suite on both JDK 11 and JDK 23, and connecting to both Oracle Database 19(ADB) and 23. I also ran the OracleR2dbcRepositoryIntegrationTests from the Spring Data R2DBC Project.

The Oracle JDBC dependency is updated to version 23.6, and the Project Reactor dependency to version 3.6.11.

README Changes

Implementation Changes The only significant change in our implementation is the addition of an addCloseTask method in OracleConnectionImpl. This was added to workaround a defect (bug #37160069) in the 23.6 release of Oracle JDBC. The defect causes closeAsyncOracle to fail when a Blob, Clob, or a SELECT ... FOR UPDATE ResultSet are still open. To avoid this scenario, we can use addCloseTask to ensure that LOBs and ResultSets are freed/closed before calling closeAsyncOracle. This change brought a slight refactoring to the constructors of many classes. These classes will now be constructed with a reference to the OracleConnectionImpl that created them. This allows the classes to access the addCloseTask method. My hope is that any functionality we add in the future can also be accessed through a method of OracleConnectionImpl.

Another change in our implementation is that Blob.discard() and Clob.discard() will no longer be called when a Blob or Clob is set as a bind value. It is not clear to me why this call was present in the OracleStatementImpl code to begin with. I am fairly sure it is not correct to do this though. If Oracle R2DBC did not create the Blob/Clob, then it should not be discarding it; The user who created the Blob/Clob should do instead.

Test Code Changes