Improve error message "The application must supply JDBC connections"

Description

Creating a simple `RESOURCE_LOCAL` persistence unit where connection properties `javax.persistence.jdbc.driver`, `javax.persistence.jdbc.url`, `javax.persistence.jdbc.user` and `javax.persistence.jdbc.password` are specified in source code and passed to `EntityManagerFactory.createEntityManager(Map)` can fail with

which isn't overly helpful because a connection is supplied - something else is meant here, but that something should be explained to the user. In case this feedback can't be improved, suggestions of the cause have to be supplied in the exception message, i.e. `The application must supply JDBC connections (did you forget to specify xyz at abc (was empty))`.

EclipseLink fails with

Please note that this is not a support request for workaround and possible causes of the issue and I'm not eager to get this fixed for myself, but rather for everyone.

An example can be found at https://github.com/krichter722/hibernate-supply-connections-feedback.

Environment

None

Assignee

Unassigned

Reporter

Karl-Philipp Richter

Fix versions

None

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Affects versions

Priority

Major
Configure