The JDBC 4.3 methods createConnectionBuilder()
and createShardingKeyBuilder()
(available as of JDK 9) have default implementations which just throw a not-supported exception. For Spring's DelegatingDataSource
and AbstractRoutingDataSource
, we can introduce delegation support for those methods, invoking the corresponding methods on the target DataSource. This makes it available on all of Spring's common DataSource adapters and proxies - usually without special decoration but at least allowing the same degree of access as on the target DataSource itself.
This goes along with #31506.