From f967e16fee9b6cab7b726e7edcb60849accd6011 Mon Sep 17 00:00:00 2001 From: Karel Maesen Date: Fri, 12 Nov 2021 14:32:09 +0100 Subject: [PATCH] HHH-14925 Using JavaTypeRegistry#findDescriptor() --- .../hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java | 2 +- .../org/hibernate/sql/exec/internal/AbstractJdbcParameter.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java b/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java index fd672f7390..0097342690 100644 --- a/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java +++ b/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java @@ -1467,7 +1467,7 @@ public class SqmCriteriaNodeBuilder implements NodeBuilder, SqmCreationContext, basicType = getTypeConfiguration().getBasicTypeForJavaType( valueClass ); if ( basicType == null ) { final JavaType javaType = getTypeConfiguration().getJavaTypeDescriptorRegistry() - .getDescriptor( valueClass ); + .findDescriptor( valueClass ); if ( javaType != null ) { final JdbcType recommendedJdbcType = javaType.getRecommendedJdbcType( getTypeConfiguration().getCurrentBaseSqlTypeIndicators() ); if ( recommendedJdbcType != null ) { diff --git a/hibernate-core/src/main/java/org/hibernate/sql/exec/internal/AbstractJdbcParameter.java b/hibernate-core/src/main/java/org/hibernate/sql/exec/internal/AbstractJdbcParameter.java index 8d2b1cb2d9..3e4352aa3c 100644 --- a/hibernate-core/src/main/java/org/hibernate/sql/exec/internal/AbstractJdbcParameter.java +++ b/hibernate-core/src/main/java/org/hibernate/sql/exec/internal/AbstractJdbcParameter.java @@ -126,7 +126,7 @@ public abstract class AbstractJdbcParameter return defaultForJavaType; } - final JavaType javaType = typeConfiguration.getJavaTypeDescriptorRegistry().getDescriptor( valueClass ); + final JavaType javaType = typeConfiguration.getJavaTypeDescriptorRegistry().findDescriptor( valueClass ); if ( javaType != null ) { final JdbcType recommendedJdbcType = javaType.getRecommendedJdbcType( typeConfiguration.getCurrentBaseSqlTypeIndicators() ); if ( recommendedJdbcType != null ) {