Document actual status of orm.hibernate5 and Hibernate JPA support
See gh-35111
This commit is contained in:
parent
f84552a97e
commit
0bee65482f
|
@ -14,9 +14,9 @@ As of Spring Framework 6.0, Spring requires Hibernate ORM 5.5+ for Spring's
|
|||
`HibernateJpaVendorAdapter` as well as for a native Hibernate `SessionFactory` setup.
|
||||
We recommend Hibernate ORM 5.6 as the last feature branch in that Hibernate generation.
|
||||
|
||||
Hibernate ORM 6.x is only supported as a JPA provider (`HibernateJpaVendorAdapter`).
|
||||
Plain `SessionFactory` setup with the `orm.hibernate5` package is not supported anymore.
|
||||
We recommend Hibernate ORM 6.1/6.2 with JPA-style setup for new development projects.
|
||||
Hibernate ORM 6.x is primarily supported as a JPA provider (`HibernateJpaVendorAdapter`).
|
||||
Plain `SessionFactory` setup with the `orm.hibernate5` package is tolerated for migration
|
||||
purposes. We recommend Hibernate ORM 6.x with JPA-style setup for new development projects.
|
||||
====
|
||||
|
||||
|
||||
|
|
|
@ -97,10 +97,6 @@ import org.springframework.util.Assert;
|
|||
* support nested transactions! Hence, do not expect Hibernate access code to
|
||||
* semantically participate in a nested transaction.</i>
|
||||
*
|
||||
* <p><b>NOTE: Hibernate ORM 6.x is officially only supported as a JPA provider.
|
||||
* Please use {@link org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean}
|
||||
* with {@link org.springframework.orm.jpa.JpaTransactionManager} there instead.</b>
|
||||
*
|
||||
* @author Juergen Hoeller
|
||||
* @since 4.2
|
||||
* @see #setSessionFactory
|
||||
|
@ -285,10 +281,9 @@ public class HibernateTransactionManager extends AbstractPlatformTransactionMana
|
|||
/**
|
||||
* Set whether to operate on a Hibernate-managed Session instead of a
|
||||
* Spring-managed Session, that is, whether to obtain the Session through
|
||||
* Hibernate's {@link SessionFactory#getCurrentSession()}
|
||||
* instead of {@link SessionFactory#openSession()} (with a Spring
|
||||
* {@link TransactionSynchronizationManager}
|
||||
* check preceding it).
|
||||
* Hibernate's {@link SessionFactory#getCurrentSession()} instead of
|
||||
* {@link SessionFactory#openSession()} (with a Spring
|
||||
* {@link TransactionSynchronizationManager} check preceding it).
|
||||
* <p>Default is "false", i.e. using a Spring-managed Session: taking the current
|
||||
* thread-bound Session if available (for example, in an Open-Session-in-View scenario),
|
||||
* creating a new Session for the current transaction otherwise.
|
||||
|
|
|
@ -68,10 +68,6 @@ import org.springframework.lang.Nullable;
|
|||
* {@link HibernateTransactionManager}, this naturally allows for mixing JPA access code
|
||||
* with native Hibernate access code within the same transaction.
|
||||
*
|
||||
* <p><b>NOTE: Hibernate ORM 6.x is officially only supported as a JPA provider.
|
||||
* Please use {@link org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean}
|
||||
* with {@link org.springframework.orm.jpa.JpaTransactionManager} there instead.</b>
|
||||
*
|
||||
* @author Juergen Hoeller
|
||||
* @since 4.2
|
||||
* @see #setDataSource
|
||||
|
|
|
@ -1,14 +1,11 @@
|
|||
/**
|
||||
* Package providing integration of
|
||||
* <a href="https://hibernate.org/">Hibernate 5.x</a>
|
||||
* <a href="https://hibernate.org/">Hibernate ORM 5.x</a>
|
||||
* with Spring concepts.
|
||||
*
|
||||
* <p>Contains an implementation of Spring's transaction SPI for local Hibernate transactions.
|
||||
* This package is intentionally rather minimal, with no template classes or the like,
|
||||
* in order to follow Hibernate recommendations as closely as possible. We recommend
|
||||
* using Hibernate's native <code>sessionFactory.getCurrentSession()</code> style.
|
||||
*
|
||||
* <p><b>This package supports Hibernate 5.x only.</b>
|
||||
* <p>This package supports Hibernate 5.x while also tolerating use against
|
||||
* Hibernate ORM 6.x for migration purposes. Note that we strongly recommend
|
||||
* Hibernate's native <code>sessionFactory.getCurrentSession()</code> style.
|
||||
*/
|
||||
@NonNullApi
|
||||
@NonNullFields
|
||||
|
|
|
@ -75,7 +75,7 @@ import org.springframework.util.ReflectionUtils;
|
|||
|
||||
/**
|
||||
* {@link org.springframework.orm.jpa.JpaDialect} implementation for Hibernate.
|
||||
* Compatible with Hibernate ORM 5.5/5.6 as well as 6.0/6.1/6.2/6.3.
|
||||
* Compatible with Hibernate ORM 5.5/5.6 as well as 6.x.
|
||||
*
|
||||
* @author Juergen Hoeller
|
||||
* @author Costin Leau
|
||||
|
|
|
@ -47,7 +47,7 @@ import org.springframework.util.ClassUtils;
|
|||
|
||||
/**
|
||||
* {@link org.springframework.orm.jpa.JpaVendorAdapter} implementation for Hibernate.
|
||||
* Compatible with Hibernate ORM 5.5/5.6 as well as 6.0/6.1/6.2/6.3.
|
||||
* Compatible with Hibernate ORM 5.5/5.6 as well as 6.x.
|
||||
*
|
||||
* <p>Exposes Hibernate's persistence provider and Hibernate's Session as extended
|
||||
* EntityManager interface, and adapts {@link AbstractJpaVendorAdapter}'s common
|
||||
|
|
Loading…
Reference in New Issue