HHH-13698 : Hibernate does not recognize MySQL 8 error code 3572 as PessimisticLockException

This commit is contained in:
Gail Badner 2019-10-30 14:08:45 -07:00 committed by gbadner
parent a7f017c3dc
commit 0c1df5fc0d
1 changed files with 2 additions and 1 deletions

View File

@ -532,7 +532,8 @@ public class MySQLDialect extends Dialect {
@Override
public JDBCException convert(SQLException sqlException, String message, String sql) {
switch ( sqlException.getErrorCode() ) {
case 1205: {
case 1205:
case 3572: {
return new PessimisticLockException( message, sqlException, sql );
}
case 1207: