[hibernate-issues] [Hibernate-JIRA] Resolved: (HHH-7089) NPE during SessionFactoryImpl init when 2L caching is enabled and @NaturalIdCache is used with EHcache
Steve Ebersole (JIRA)
noreply at atlassian.com
Thu Mar 1 11:26:48 EST 2012
[ https://hibernate.onjira.com/browse/HHH-7089?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Steve Ebersole resolved HHH-7089.
---------------------------------
Resolution: Fixed
Fix Version/s: 4.1.1
> NPE during SessionFactoryImpl init when 2L caching is enabled and @NaturalIdCache is used with EHcache
> ------------------------------------------------------------------------------------------------------
>
> Key: HHH-7089
> URL: https://hibernate.onjira.com/browse/HHH-7089
> Project: Hibernate ORM
> Issue Type: Bug
> Affects Versions: 4.1.0
> Reporter: Eric Dalquist
> Assignee: Steve Ebersole
> Fix For: 4.1.1
>
> Time Spent: 11m
>
> The org.hibernate.cache.ehcache.SingletonEhCacheRegionFactory always returns null for buildNaturalIdRegion due to an oversight during work on HHH-6974
> The result is that if Second-Level caching is enabled and any entity is annotated with @NaturalIdCache session factory creation fails with a NPE
> {noformat}
> [java] Caused by: java.lang.NullPointerException
> [java] at org.hibernate.internal.SessionFactoryImpl.<init>(SessionFactoryImpl.java:361)
> [java] at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1740)
> [java] at org.hibernate.ejb.EntityManagerFactoryImpl.<init>(EntityManagerFactoryImpl.java:88)
> [java] at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:904)
> [java] at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:889)
> [java] at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:73)
> {noformat}
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list