diff --git a/hibernate-core/src/main/java/org/hibernate/cfg/AvailableSettings.java b/hibernate-core/src/main/java/org/hibernate/cfg/AvailableSettings.java index a0c71dbfa416..33b751ca7eae 100644 --- a/hibernate-core/src/main/java/org/hibernate/cfg/AvailableSettings.java +++ b/hibernate-core/src/main/java/org/hibernate/cfg/AvailableSettings.java @@ -106,6 +106,7 @@ public interface AvailableSettings * @since 5.3 */ @Deprecated(since = "7.0", forRemoval = true) + @SuppressWarnings("DeprecatedIsStillUsed") String DELAY_ENTITY_LOADER_CREATIONS = "hibernate.loader.delay_entity_loader_creations"; /** @@ -157,6 +158,7 @@ public interface AvailableSettings * @deprecated This is no longer useful and will be removed. */ @Deprecated(since = "7.0", forRemoval = true) + @SuppressWarnings("DeprecatedIsStillUsed") String DISCARD_PC_ON_CLOSE = "hibernate.discard_pc_on_close"; /** diff --git a/hibernate-core/src/main/java/org/hibernate/cfg/BatchSettings.java b/hibernate-core/src/main/java/org/hibernate/cfg/BatchSettings.java index 01e89517eba2..f6e7e522b4e2 100644 --- a/hibernate-core/src/main/java/org/hibernate/cfg/BatchSettings.java +++ b/hibernate-core/src/main/java/org/hibernate/cfg/BatchSettings.java @@ -69,5 +69,6 @@ public interface BatchSettings { * @deprecated Use {@link #BUILDER} instead */ @Deprecated(since="6.4") + @SuppressWarnings("DeprecatedIsStillUsed") String BATCH_STRATEGY = "hibernate.jdbc.factory_class"; } diff --git a/hibernate-core/src/main/java/org/hibernate/cfg/BytecodeSettings.java b/hibernate-core/src/main/java/org/hibernate/cfg/BytecodeSettings.java index 30a425fac764..b2e61cab685f 100644 --- a/hibernate-core/src/main/java/org/hibernate/cfg/BytecodeSettings.java +++ b/hibernate-core/src/main/java/org/hibernate/cfg/BytecodeSettings.java @@ -24,6 +24,7 @@ public interface BytecodeSettings { * See HHH-17643 */ @Deprecated( forRemoval = true ) + @SuppressWarnings("DeprecatedIsStillUsed") String BYTECODE_PROVIDER = "hibernate.bytecode.provider"; /** diff --git a/hibernate-core/src/main/java/org/hibernate/cfg/JdbcSettings.java b/hibernate-core/src/main/java/org/hibernate/cfg/JdbcSettings.java index 4c59d442ecd6..a4b7062ad590 100644 --- a/hibernate-core/src/main/java/org/hibernate/cfg/JdbcSettings.java +++ b/hibernate-core/src/main/java/org/hibernate/cfg/JdbcSettings.java @@ -15,7 +15,7 @@ import org.hibernate.sql.ast.spi.ParameterMarkerStrategy; /** - * Settings related to JDBC, Connections, pools, Dialects, etc + * Settings related to JDBC, Connections, pools, Dialects, and so on. * * @author Steve Ebersole */ @@ -162,7 +162,7 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett /** * Used in conjunction with {@value #JAKARTA_HBM2DDL_DB_NAME} for the purpose of * determining the {@link org.hibernate.dialect.Dialect} to use when the name does - * not provide enough detail. + * not provide enough information. *

* The value is expected to match what would be returned from * {@link java.sql.DatabaseMetaData#getDatabaseProductVersion()}) for the @@ -175,7 +175,7 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett /** * Used in conjunction with {@value #JAKARTA_HBM2DDL_DB_NAME} for the purpose of * determining the {@link org.hibernate.dialect.Dialect} to use when the name does - * not provide enough detail. + * not provide enough information. *

* The value is expected to match what would be returned from * {@link java.sql.DatabaseMetaData#getDatabaseMajorVersion()}) for the underlying @@ -188,7 +188,7 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett /** * Used in conjunction with {@value #JAKARTA_HBM2DDL_DB_NAME} for the purpose of * determining the {@link org.hibernate.dialect.Dialect} to use when the name does - * not provide enough detail. + * not provide enough information. *

* The value is expected to match what would be returned from * {@link java.sql.DatabaseMetaData#getDatabaseMinorVersion()}) for the underlying @@ -258,7 +258,7 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett * The default implementation is not recommended for use in production. * * @apiNote The term {@code "class"} appears in the setting name due to legacy reasons; - * however it can accept instances. + * however, it can accept instances. */ String CONNECTION_PROVIDER = "hibernate.connection.provider_class"; @@ -303,14 +303,15 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett /** * Indicates that connections obtained from the configured {@link ConnectionProvider} have - * auto-commit already disabled when they are acquired. + * {@linkplain java.sql.Connection#getAutoCommit auto-commit} already disabled when they + * are acquired. *

* It is inappropriate to set this value to {@code true} when the connections returned by * the provider do not, in fact, have auto-commit disabled. Doing so may lead to Hibernate * executing SQL operations outside the scope of any transaction. * * @apiNote By default, Hibernate calls {@link java.sql.Connection#setAutoCommit(boolean)} - * on newly-obtained connections. With this setting enabled, that call is skipped, along + * on newly obtained connections. With this setting enabled, that call is skipped, along * with some other operations, in the interest of performance. * * @settingDefault {@code false} @@ -332,6 +333,7 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett * and {@link org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProvider}. */ @Deprecated(since="7") + @SuppressWarnings("DeprecatedIsStillUsed") String CONNECTION_PREFIX = "hibernate.connection"; /** @@ -340,7 +342,7 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett * either: *

* @@ -423,6 +425,7 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett * @deprecated It's not necessary to set this explicitly */ @Deprecated(since = "7", forRemoval = true) + @SuppressWarnings("DeprecatedIsStillUsed") String USE_SCROLLABLE_RESULTSET = "hibernate.jdbc.use_scrollable_resultset"; /** @@ -539,12 +542,12 @@ public interface JdbcSettings extends C3p0Settings, AgroalSettings, HikariCPSett * Whether access to JDBC {@linkplain java.sql.DatabaseMetaData metadata} is allowed during bootstrap. *

* Typically, Hibernate accesses this metadata to understand the capabilities of the underlying - * database to help minimize needed configuration. Disabling this access means that only explicit - * settings are used. At a minimum, the Dialect to use must be specified using either the {@value #DIALECT} - * or {@value JdbcSettings#JAKARTA_HBM2DDL_DB_NAME} setting. When the Dialect to use is specified in + * database to help minimize needed configuration. Disabling this access means that only explicit + * settings are used. At a minimum, the Dialect to use must be specified using either the {@value #DIALECT} + * or {@value JdbcSettings#JAKARTA_HBM2DDL_DB_NAME} setting. When the Dialect to use is specified in * this manner it is generally a good idea to specify the - * {@linkplain JdbcSettings#JAKARTA_HBM2DDL_DB_VERSION database version} as well - Dialects use the version - * to configure themselves. + * {@linkplain JdbcSettings#JAKARTA_HBM2DDL_DB_VERSION database version} as well - Dialects use the + * version to configure themselves. * * @apiNote The specified Dialect may also provide defaults into the "explicit" settings. * diff --git a/hibernate-core/src/main/java/org/hibernate/cfg/JpaComplianceSettings.java b/hibernate-core/src/main/java/org/hibernate/cfg/JpaComplianceSettings.java index 693e39447491..47c193d36ed3 100644 --- a/hibernate-core/src/main/java/org/hibernate/cfg/JpaComplianceSettings.java +++ b/hibernate-core/src/main/java/org/hibernate/cfg/JpaComplianceSettings.java @@ -190,5 +190,6 @@ public interface JpaComplianceSettings { * @deprecated Prefer {@link #JPA_QUERY_COMPLIANCE} */ @Deprecated + @SuppressWarnings("DeprecatedIsStillUsed") String JPAQL_STRICT_COMPLIANCE= "hibernate.query.jpaql_strict_compliance"; } diff --git a/hibernate-core/src/main/java/org/hibernate/cfg/ManagedBeanSettings.java b/hibernate-core/src/main/java/org/hibernate/cfg/ManagedBeanSettings.java index 3b760cb28c23..ba99ca80db48 100644 --- a/hibernate-core/src/main/java/org/hibernate/cfg/ManagedBeanSettings.java +++ b/hibernate-core/src/main/java/org/hibernate/cfg/ManagedBeanSettings.java @@ -80,8 +80,8 @@ public interface ManagedBeanSettings { String DELAY_CDI_ACCESS = "hibernate.delay_cdi_access"; /** - * Controls whether Hibernate can try to create beans other than converters - * and listeners using CDI. Only meaningful when a CDI {@link #BEAN_CONTAINER container} + * Controls whether Hibernate can try to create beans other than converters and + * listeners using CDI. Only meaningful when a CDI {@link #BEAN_CONTAINER container} * is used. *

* By default, Hibernate will only attempt to create converter and listener beans using CDI. diff --git a/hibernate-core/src/main/java/org/hibernate/cfg/MappingSettings.java b/hibernate-core/src/main/java/org/hibernate/cfg/MappingSettings.java index ebb742465432..561932b649aa 100644 --- a/hibernate-core/src/main/java/org/hibernate/cfg/MappingSettings.java +++ b/hibernate-core/src/main/java/org/hibernate/cfg/MappingSettings.java @@ -326,8 +326,8 @@ public interface MappingSettings { String XML_FORMAT_MAPPER = "hibernate.type.xml_format_mapper"; /** - * Specifies whether to use the legacy provider specific and non-portable XML format for collections and byte arrays - * for XML serialization/deserialization. + * Specifies whether to use the legacy provider-specific and non-portable XML format for + * collections and byte arrays for XML serialization/deserialization. *

* {@code false} by default. This property only exists for backwards compatibility. * @@ -355,8 +355,8 @@ public interface MappingSettings { * The possible options for this setting are enumerated by * {@link org.hibernate.annotations.TimeZoneStorageType}. * - * @apiNote For backward compatibility with older versions of Hibernate, set this property to - * {@link org.hibernate.annotations.TimeZoneStorageType#NORMALIZE NORMALIZE}. + * @apiNote For backward compatibility with older versions of Hibernate, set this property + * to {@link org.hibernate.annotations.TimeZoneStorageType#NORMALIZE NORMALIZE}. * * @settingDefault {@link org.hibernate.annotations.TimeZoneStorageType#DEFAULT DEFAULT}, * which guarantees that the {@linkplain java.time.OffsetDateTime#toInstant() instant} @@ -374,7 +374,7 @@ public interface MappingSettings { * Used to specify the {@link org.hibernate.boot.model.naming.ImplicitNamingStrategy} * class to use. The following shortcut names are defined for this setting: *