Skip to content

NoSuchMethodError from oracle.ucp.jdbc.PoolDataSource.getPassword() when deriving a DataSource from a UCP PoolDataSourceImpl #28127

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wilkinsona opened this issue Sep 24, 2021 · 0 comments
Assignees
Labels
type: bug A general bug
Milestone

Comments

@wilkinsona
Copy link
Member

wilkinsona commented Sep 24, 2021

PoolDataSource is an interface and the getPassword() method has been deprecated. It appears to be a default method that isn't implemented by PoolDataSourceImpl. The default method has been implemented in PoolDataSource to throw a NoSuchMethodError:

java.lang.NoSuchMethodError: this method is deprecated
	at oracle.ucp.jdbc.PoolDataSource.getPassword(PoolDataSource.java:462)
	at org.springframework.boot.jdbc.DataSourceBuilder$OraclePoolDataSourceProperties.lambda$7(DataSourceBuilder.java:655)
	at org.springframework.boot.jdbc.DataSourceBuilder$MappedDataSourceProperty.get(DataSourceBuilder.java:474)
	at org.springframework.boot.jdbc.DataSourceBuilder$MappedDataSourceProperties.get(DataSourceBuilder.java:363)
	at org.springframework.boot.jdbc.DataSourceBuilder.build(DataSourceBuilder.java:178)

We need to update DataSourceBuilder to behave as if the method's not there at all.

@wilkinsona wilkinsona added the type: bug A general bug label Sep 24, 2021
@wilkinsona wilkinsona added this to the 2.6.x milestone Sep 24, 2021
@wilkinsona wilkinsona self-assigned this Sep 24, 2021
@wilkinsona wilkinsona modified the milestones: 2.6.x, 2.6.0-RC1 Sep 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

1 participant