Skip to content

Improve error message for obtaining a JDBC connection #2186

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

Open
DavideD opened this issue Apr 7, 2025 · 1 comment
Open

Improve error message for obtaining a JDBC connection #2186

DavideD opened this issue Apr 7, 2025 · 1 comment
Labels
enhancement New feature or request good first issue Good for newcomers
Milestone

Comments

@DavideD
Copy link
Member

DavideD commented Apr 7, 2025

When the application tries to access a JDBC connection, we throw the following error:

Caused by: java.sql.SQLException: Not using JDBC

This happens in NoJdbcConnectionProvider#getConnection.

When this happens, it means that we haven't tested a particular mapping or configuration. In a perfect world, a user should never see this error.

We should think of a better error message to explain the user that their use case is currently non supported.
And it makes sense to add the error in the logger.

@DavideD DavideD added the enhancement New feature or request label Apr 7, 2025
@DavideD DavideD added this to the next milestone Apr 7, 2025
@DavideD DavideD added the good first issue Good for newcomers label Apr 7, 2025
@yrodiere
Copy link
Member

yrodiere commented Apr 7, 2025

+1 it does seem like a quick way to massively improve the experience of new users.

@DavideD DavideD modified the milestones: 3.0.0.Beta3, next Apr 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants