Persistence In Oc4j (Doc ID 1097823.1)

Last updated on SEPTEMBER 15, 2017

Applies to:

Oracle Containers for J2EE - Version 10.1.3.4.0 and later
Information in this document applies to any platform.

Symptoms


While deploying a Hibernate/Spring application to oc4j 10.1.3.4, the following exception occurs :

Error creating bean with name 'sessionFactory' defined in class path resource [spring-commons/applicationContext-hibernate.xml]: Invocation of init method failed; nested exception is java.lang.NoSuchMethodError: javax/persistence/OneToMany.orphanRemoval()Z
10/04/19 10:17:21       at org.springframework.beans.factory.access.SingletonBeanFactoryLocator.useBeanFactory(SingletonBeanFactoryLocator.java:389)
10/04/19 10:17:21       at org.springframework.web.context.ContextLoader.loadParentContext(ContextLoader.java:341)
10/04/19 10:17:21       at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:195)

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms