Weird exception thrown on query timeout having PostgreSQL as the underlying database

Description

When an exception is thrown due to an expiration of a Query timeout an org.hibernate.exception.GenericJDBCException exception is thrown when the underlying database is PostgreSQL (See attached stack trace). This forces to do some extra work to identify that the exception is caused because of the timeout.

Note that when using Oracle the correct javax.persistence.QueryTimeoutException is thrown instead.

Environment

None

Status

Assignee

Unassigned

Reporter

Carlos Aristu

Fix versions

None

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

Priority

Minor
Configure