You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by "schizophrenicmaniac (via GitHub)" <gi...@apache.org> on 2026/10/22 00:46:38 UTC

[PR] Fix Proxy startup failure when dataSourceClassName is HikariDataSource [shardingsphere]

schizophrenicmaniac opened a new pull request, #40324:
URL: https://github.com/apache/shardingsphere/pull/40324

   Fixes #40303.
   
   Changes proposed in this pull request:
     - When a Proxy storage unit sets `dataSourceClassName: com.zaxxer.hikari.HikariDataSource`, `DataSourcePoolPropertiesCreator` also copied that value into the pool properties. Hikari then got its own class through `setDataSourceClassName` and created a second HikariDataSource inside the first. The MySQL default URL properties (like `elideSetAutoCommits`) were applied to that inner pool, which doesn't have them, so Proxy failed at startup with "Property elideSetAutoCommits does not exist on target class com.zaxxer.hikari.HikariDataSource".
     - The creator now leaves `dataSourceClassName` out of the pool properties for Hikari, the same way `YamlDataSourceConfigurationSwapper` already does for JDBC YAML configs. Other pool classes are unchanged.
     - Added a unit test in `DataSourcePoolPropertiesCreatorTest` and a release note entry.
   
   ---
   
   Before submitting this PR, I confirm that:
   - [x] My code follows the [code of conduct](https://shardingsphere.apache.org/community/en/involved/conduct/code/) of this project.
   - [x] I have reviewed my changes.
   - [ ] I have (or in comment I request) added corresponding labels for the pull request.
   - [x] I have passed the required local checks: `./mvnw clean install -B -T1C -Pcheck`.
   - [ ] I have updated the relevant documentation, if applicable.
   - [x] I have added or updated unit tests for my changes, if applicable.
   - [x] I have updated the Release Notes of the current development version, if applicable. For more details, see [Update Release Note](https://shardingsphere.apache.org/community/en/involved/contribute/contributor/).
   
   AI disclosure: drafted with Claude Code (Claude Opus 5.5); files: RELEASE-NOTES.md, DataSourcePoolPropertiesCreator.java, DataSourcePoolPropertiesCreatorTest.java.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Fix Proxy startup failure when dataSourceClassName is HikariDataSource [shardingsphere]

Posted by "schizophrenicmaniac (via GitHub)" <gi...@apache.org>.
schizophrenicmaniac commented on PR #40324:
URL: https://github.com/apache/shardingsphere/pull/40324#issuecomment-6338854417

   @terrymanu Thanks, agreed. I removed the Hikari check from DataSourcePoolPropertiesCreator and added `dataSourceClassName` = `com.zaxxer.hikari.HikariDataSource` to the skipped properties in HikariDataSourcePoolMetaData, so DataSourcePoolCreator filters it before calling setters. The regression test is now in HikariDataSourcePoolCreatorTest (the created HikariDataSource has no dataSourceClassName), and HikariDataSourcePoolMetaDataTest checks the new skipped entry. The core module no longer differs from master.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Fix Proxy startup failure when dataSourceClassName is HikariDataSource [shardingsphere]

Posted by "terrymanu (via GitHub)" <gi...@apache.org>.
terrymanu merged PR #40324:
URL: https://github.com/apache/shardingsphere/pull/40324


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org