"is not a known entity" error from EclipseLink

Hi,
I'm seeing a strange behavior in Weblogic (10.3.3) when using EclipseLink (2.0.2).
Here is what I do. I use Maven to compile a project in which I use JPA (1.0.2). In this project, module *"A"* depends on module *"B"*. "B" contains a bunch of Entities ( javax.persistence.Entity_ ). But *"persistence.xml"* is in "A" in which all entities of "B" are registered. "B" is deployed as an Optional Package and "A" refers to it via its MANIFEST.
Deployment is successful but when I run the application and try to persist an entity I get the above error in "A".
One of the following actions will solve it:
- Restart the weblogic server
- Update module A's POM file and explicitly add a dependency to module B. Originally this dependency is not there because classes in module A accept "Object" and pass that through to EntityManager (not explicitly the entity class type). Adding this dependency doesn't change the JAR file's manifest in anyway. It only update the "maven" directory in JAR file's META-INF folder. I don't think weblogic even care about this folder.
Why should this be the case?
I downloaded EclipseLinks' source and debugged the application. It seems that the problem occurs because "*+descriptors+*" collection field in "*+org.eclipse.persistence.internal.sessions.AbstractSession+*" class doesn't have the entity's descriptor and thus it doesn't recognize it as an Entity. I reckon restarting the server updates that cache. But what about the second solution? Why is that working? Is "maven" directory in JAR file's META-INF directory known to weblogic?
Edited by: Keibi on Jul 11, 2012 5:36 PM
Edited by: Keibi on Jul 11, 2012 5:37 PM

How would moving the persistence.xml file help?
Here is the stacktrace:
Error 500--Internal Server Error
javax.ejb.EJBTransactionRolledbackException: EJB Exception: : java.lang.IllegalArgumentException: Object: com.xxx.entities.XyzEntity@13b8dea is not a known entity type.
     at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.registerNewObjectForPersist(UnitOfWorkImpl.java:4184)
     at org.eclipse.persistence.internal.jpa.EntityManagerImpl.persist(EntityManagerImpl.java:368)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:93)
     at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:91)
     at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:80)
     at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:26)
     at $Proxy68.persist(Unknown Source)
     at com.xxx.persistence.DatabaseBean.PersistEntity(DatabaseBean.java:19)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:37)
     at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:54)
     at com.bea.core.repackaged.springframework.jee.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:50)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
     at $Proxy74.PersistEntity(Unknown Source)
     at com.xxx.persistence.DatabaseBean_7z3dqu_DatabaseImpl.PersistEntity(DatabaseBean_7z3dqu_DatabaseImpl.java:56)
     at com.xxx.persistence.DatabaseBean_7z3dqu_DatabaseImpl_WLSkel.invoke(Unknown Source)
     at weblogic.rmi.internal.ServerRequest.sendReceive(ServerRequest.java:174)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:345)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:259)
     at com.xxx.persistence.DatabaseBean_7z3dqu_DatabaseImpl_1033_WLStub.PersistEntity(Unknown Source)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:84)
     at $Proxy72.PersistEntity(Unknown Source)
     at com.xxx.bll.PlaceOrderBean.Save(PlaceOrderBean.java:21)
     at com.xxx.bll.PlaceOrderBean.addOrder(PlaceOrderBean.java:17)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:37)
     at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:54)
     at com.bea.core.repackaged.springframework.jee.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:50)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
     at $Proxy73.addOrder(Unknown Source)
     at com.xxx.bll.PlaceOrderBean_u8t8vo_PlaceOrderImpl.addOrder(PlaceOrderBean_u8t8vo_PlaceOrderImpl.java:56)
     at com.xxx.bll.PlaceOrderBean_u8t8vo_PlaceOrderImpl_WLSkel.invoke(Unknown Source)
     at weblogic.rmi.internal.ServerRequest.sendReceive(ServerRequest.java:174)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:345)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:259)
     at com.xxx.bll.PlaceOrderBean_u8t8vo_PlaceOrderImpl_1033_WLStub.addOrder(Unknown Source)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:84)
     at $Proxy71.addOrder(Unknown Source)
     at com.xxx.web.PlaceOrderServlet.service(PlaceOrderServlet.java:32)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
     at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
     at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
     at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
     at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:183)
     at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.doIt(WebAppServletContext.java:3686)
     at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3650)
     at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
     at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
     at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2268)
     at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2174)
     at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1446)
     at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
     at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
; nested exception is:
     java.lang.IllegalArgumentException: Object: com.xxx.entities.XyzEntity@13b8dea is not a known entity type.; nested exception is: java.lang.IllegalArgumentException: Object: com.xxx.entities.XyzEntity@13b8dea is not a known entity type.
     at weblogic.ejb.container.internal.BaseRemoteObject.handleSystemException(BaseRemoteObject.java:818)
     at weblogic.ejb.container.internal.BaseRemoteObject.postInvoke1(BaseRemoteObject.java:518)
     at weblogic.ejb.container.internal.StatelessRemoteObject.postInvoke1(StatelessRemoteObject.java:49)
     at weblogic.ejb.container.internal.BaseRemoteObject.__WL_postInvokeTxRetry(BaseRemoteObject.java:445)
     at com.xxx.persistence.DatabaseBean_7z3dqu_DatabaseImpl.PersistEntity(DatabaseBean_7z3dqu_DatabaseImpl.java:68)
     at com.xxx.persistence.DatabaseBean_7z3dqu_DatabaseImpl_WLSkel.invoke(Unknown Source)
     at weblogic.rmi.internal.ServerRequest.sendReceive(ServerRequest.java:174)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:345)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:259)
     at com.xxx.persistence.DatabaseBean_7z3dqu_DatabaseImpl_1033_WLStub.PersistEntity(Unknown Source)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:84)
     at $Proxy72.PersistEntity(Unknown Source)
     at com.xxx.bll.PlaceOrderBean.Save(PlaceOrderBean.java:21)
     at com.xxx.bll.PlaceOrderBean.addOrder(PlaceOrderBean.java:17)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:37)
     at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:54)
     at com.bea.core.repackaged.springframework.jee.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:50)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
     at $Proxy73.addOrder(Unknown Source)
     at com.xxx.bll.PlaceOrderBean_u8t8vo_PlaceOrderImpl.addOrder(PlaceOrderBean_u8t8vo_PlaceOrderImpl.java:56)
     at com.xxx.bll.PlaceOrderBean_u8t8vo_PlaceOrderImpl_WLSkel.invoke(Unknown Source)
     at weblogic.rmi.internal.ServerRequest.sendReceive(ServerRequest.java:174)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:345)
     at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:259)
     at com.xxx.bll.PlaceOrderBean_u8t8vo_PlaceOrderImpl_1033_WLStub.addOrder(Unknown Source)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:84)
     at $Proxy71.addOrder(Unknown Source)
     at com.xxx.web.PlaceOrderServlet.service(PlaceOrderServlet.java:32)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
     at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
     at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
     at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
     at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:183)
     at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.doIt(WebAppServletContext.java:3686)
     at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3650)
     at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
     at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
     at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2268)
     at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2174)
     at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1446)
     at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
     at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
Caused by: java.lang.IllegalArgumentException: Object: com.xxx.entities.XyzEntity@13b8dea is not a known entity type.
     at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.registerNewObjectForPersist(UnitOfWorkImpl.java:4184)
     at org.eclipse.persistence.internal.jpa.EntityManagerImpl.persist(EntityManagerImpl.java:368)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:93)
     at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:91)
     at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:80)
     at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:26)
     at $Proxy68.persist(Unknown Source)
     at com.xxx.persistence.DatabaseBean.PersistEntity(DatabaseBean.java:19)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:597)
     at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:37)
     at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:54)
     at com.bea.core.repackaged.springframework.jee.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:50)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
     at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
     at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
     at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
     at $Proxy74.PersistEntity(Unknown Source)
     at com.xxx.persistence.DatabaseBean_7z3dqu_DatabaseImpl.PersistEntity(DatabaseBean_7z3dqu_DatabaseImpl.java:56)
     ... 61 more

Similar Messages

  • Netbeans + MySQL + Tomcat (problem with: not a known entity type)

    I try to create WebApplication with Stripes in netbeans, but I have problem with connect to DB.
    I have this code:
    EntityManagerFactory emf = Persistence.createEntityManagerFactory("jpaPU");
    EntityManager em = emf.createEntityManager();
    em.getTransaction().begin();
    Person p = new Person();
    p.setFirstName("name1");
    p.setLastName("name2");
    try
    em.persist(p);
    } catch(Exception e)
    System.out.println(e.toString());
    em.getTransaction().commit();
    em.close();
    emf.close();But in try{..} is em.persist(p); ant it prints into console this error: "java.lang.IllegalArgumentException: Object: db_entity.Person@13c7c35 is not a known entity type."
    I do not know where is problem. Could you help me, please?
    This is my persistence.xml:
    <?xml version="1.0" encoding="UTF-8"?>
    <persistence version="1.0" xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
      <persistence-unit name="jpaPU" transaction-type="RESOURCE_LOCAL">
        <provider>oracle.toplink.essentials.PersistenceProvider</provider>
        <properties>
          <property name="toplink.jdbc.user" value="root"/>
          <property name="toplink.jdbc.password" value="adminadmin"/>
          <property name="toplink.jdbc.url" value="jdbc:mysql://localhost:3306/test"/>
          <property name="toplink.jdbc.driver" value="com.mysql.jdbc.Driver"/>
          <property name="toplink.ddl-generation" value="create-tables"/>
        </properties>
      </persistence-unit>
    </persistence>When I run my application I can see in console:
    [TopLink Info]: 2008.11.15 09:01:13.265--ServerSession(4794542)--TopLink, version: Oracle TopLink Essentials - 2.0.1 (Build b09d-fcs (12/06/2007))
    [TopLink Info]: 2008.11.15 09:01:13.578--ServerSession(4794542)--file:/D:/Workspace/NetBeansProjects/jpa/build/web/WEB-INF/classes/-jpaPU login successful..so, I hope persistence.xml is good
    This is my class Person.java:
    @Entity
    public class Person implements Serializable {
        @Id
        @GeneratedValue
        private Long id;
        private String firstName;
        private String lastName;
        public void setId(Long id) { this.id = id; }
        public Long getId() { return id; }
        public String getFirstName() {  return firstName; }
        public void setFirstName(String firstName) { this.firstName = firstName;  }
        public String getLastName() { return lastName; }
        public void setLastName(String lastName) { this.lastName = lastName;  }Please, help me.

    I had the same "is not a known entity type" error when running under a development environment Eclipse/Tomcat using Toplink. But the almost same code and configuration worked when running under Eclipse as a stand-alone Java app.
    Eventually I figured out (actually trial and error), that I had checked the toplink-essentials.jar libraries to be exported under: Eclipse Project/Java Build Path/Order and Export. I was messing around with libraries. Unchecking the export option there fixed the problem.
    While its unlikely that this could have been your exact problem, I would check the library order and export configurations. Looking at other message boards about this problem, many seemed to have been caused or fixed by playing with their libraries.

  • Help with IllegalArgumentException: Object: ... is not a known entity type.

    Hi there.
    I'm trying to get TopLink JPA running with Oracle / Spring / JUnit, but so far with no success. The exception I get when trying to persist my rather simple entity is :
    java.lang.IllegalArgumentException: Object: com.yospace.tundra.mediafarm.job.Job@38b554 is not a known entity type.
         at oracle.toplink.essentials.internal.sessions.UnitOfWorkImpl.registerNewObjectForPersist(UnitOfWorkImpl.java:3198)
         at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerImpl.persist(EntityManagerImpl.java:190)
    My entity class is :
    package com.yospace.tundra.mediafarm.job;
    // imports ...
    @Entity()
    public class Job
    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    private Long id;
    public Job()
    * @return the id
    public Long getId()
    return id;
    * Set the id of this job.
    * @param id
    public void setId(Long id)
    this.id = id;
    My persistence.xml is :
    <persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence persistence_1_0.xsd" version="1.0">
    <persistence-unit name="TundraPu" transaction-type="RESOURCE_LOCAL">
    <provider>
    oracle.toplink.essentials.PersistenceProvider
    </provider>
              <!-- List all entity classes here. -->
         <class>com.yospace.tundra.mediafarm.job.Job</class>
    <properties>
    <property name="toplink.logging.level" value="FINE"/>
    </properties>
    </persistence-unit>
    </persistence>
    My spring.xml is :
    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns="http://www.springframework.org/schema/beans"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns:aop="http://www.springframework.org/schema/aop"
         xmlns:tx="http://www.springframework.org/schema/tx"
         xsi:schemaLocation="
    http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
    http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd
         http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
    <bean id="jobDao" class="com.yospace.tundra.mediafarm.job.JobDao">
    </bean>
         <!-- Location of test database configuration. -->
         <bean id="propertyConfigurer"
              class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
              <property name="locations">
                   <list>
                        <value>/test/resources/jdbc.properties</value>
                   </list>
              </property>
         </bean>
         <bean id="dataSource"
              class="org.springframework.jdbc.datasource.DriverManagerDataSource">
              <property name="driverClassName"
                   value="${jdbc.driverClassName}" />
              <property name="url" value="${jdbc.url}" />
              <property name="username" value="${jdbc.username}" />
              <property name="password" value="${jdbc.password}" />
         </bean>
         <!-- Toplink JPA entity manager configuration. -->
         <bean id="loadTimeWeaver" class="org.springframework.instrument.classloading.SimpleLoadTimeWeaver"/>
         <bean id="entityManagerFactory"
              class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
              <property name="dataSource" ref="dataSource" />
              <property name="jpaVendorAdapter">
                   <bean
                        class="org.springframework.orm.jpa.vendor.TopLinkJpaVendorAdapter">
                        <property name="databasePlatform"
                             value="${jpavendor.dialect}" />
                        <property name="generateDdl" value="true" />
                        <property name="showSql" value="true" />
                   </bean>
              </property>
              <property name="loadTimeWeaver" ref="loadTimeWeaver"/>
         </bean>
         <bean
              class="org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor" />
         <!-- JPA transaction manager configuration. -->
              <bean id="transactionManager"
              class="org.springframework.orm.jpa.JpaTransactionManager">
              <property name="entityManagerFactory"
              ref="entityManagerFactory" />
              </bean>
         <tx:annotation-driven transaction-manager="transactionManager" />
    </beans>
    This fails when I run a JUnit test under Eclipse -- it falls over on the first operation, which creates then attempts to persist a job.
    I wonder if anyone has any ideas as to what exactly I'm doing wrong ...?
    Thanks,
    Henry

    I had the same "is not a known entity type" error when running under a development environment Eclipse/Tomcat using Toplink. But the almost same code and configuration worked when running under Eclipse as a stand-alone Java app.
    Eventually I figured out (actually trial and error), that I had checked the toplink-essentials.jar libraries to be exported under: Eclipse Project/Java Build Path/Order and Export. I was messing around with libraries. Unchecking the export option there fixed the problem.
    While its unlikely that this could have been your exact problem, I would check the library order and export configurations. Looking at other message boards about this problem, many seemed to have been caused or fixed by playing with their libraries.

  • Why is apple not addressing the C   error from the LAST "update".  I cannot open itunes to see if any repair has been done.  There is nothing in apple support.

    C++ error being caused by latest "itunes update". can no longer access itunes to do anything at all, cannot check for repair update.
    Well done Apple.  Way to shut down access to your software and fail to own up to it with a workaround

    Try the following user tip (even though you're getting this for an 11.1.5.5 rather than an 11.1.4.62):
    Troubleshooting issues with iTunes for Windows updates

  • Getting 'variable not in select list' error after extending VO

    Hi,
    My page is based on two VO. one VO has all transient attribute(LearnerSearchCritVO) and used to capture Search Criteria, The other VO is used for query(LearnerSearchVO).
    I have exteneded LearnerSearchCritVO to add 4 new additional Transient attributes
    and LearnerSerachVO and its IMPL class to add additional where clause.
    After substitution and personalization when I am querying through page I am getting the following error -
    ## Detail 0 ##
    java.sql.SQLException: ORA-01007: variable not in select list
    The query is working fine at backend and the same thing was working fine before instance is refreshed.
    I am not able to find why this error is coming.
    please help me out to sort this issue.

    Hi All
    Sorry to bring this one up again, but I've had a bit of a look around and done as much as I can based on the information given in this and other threads on the subject.
    I'm getting the java.sql.SQLException: ORA-01007: variable not in select list error from my extended VO/substitution.
    The query is based on a view for easy editing after deployment, so could that have anything to do with it?
    Here's the query from the error message:
    oracle.apps.fnd.framework.OAException: oracle.jbo.SQLStmtException: JBO-27122: SQL error during statement preparation. Statement:
    SELECT * FROM (SELECT
    SSH.FULL_NAME,
    SSH.ASSIGNMENT_NUMBER,
    SSH.JOB,
    SSH.GRADE,
    SSH.ANNUALIZED_SALARY,
    SSH.CURRENCY,
    SSH.CHANGE_DATE,
    SSH.SALARY_BASIS,
    SSH.PERSON_ID,
    SSH.ASSIGNMENT_ID,
    SSH.SUPERVISOR_ID,
    SSH.LAST_CHANGE_DATE,
    SSH.PAYROLL_NAME,
    SSH.NEXT_CHANGE_DATE,
    SSH.EMPLOYEE_NUMBER,
    SSH.CWK_NUMBER,
    SSH.PERSON_TYPE,
    SSH.EFFECTIVE_DATE,
    SSH.SUPERVISOR_ASSIGNMENT_ID,
    SSH.LEGISLATIONCODE,
    SSH.MANAGER_ENABLED
    FROM XX_SAL_SUP_HRCHY_VO_V SSH) QRSLT
    WHERE (((:1 = SUPERVISOR_ID)
    AND (:2 = EFFECTIVE_DATE)
    AND (:3 = SUPERVISOR_ASSIGNMENT_ID
    OR hr_general2.supervisor_assignments_in_use = 'FALSE')))
    ORDER BY FULL_NAME
    So... What's missing?
    Any help appreciated.
    CK

  • XML parsing error: xml processing instruction not at start of external entity (error code 17)

    I created a form and recieve the filled in form by email from participants. It has always worked in the past. Recently when importing data into the master form (from filled in forms in xml files sent by applicants) I am getting this error message..."xml processing instruction not at start of external entity (error code 17), line 2, column 1...." pointing to the file of data (xml) I am trying to input.  If I pull up old data forms (from 2009) they work, but now I am getting this error.  I run Adobe Design Premium CS3 for Windows.  Can anyone tell me what to do to fix?

    I created a form and recieve the filled in form by email from participants. It has always worked in the past. Recently when importing data into the master form (from filled in forms in xml files sent by applicants) I am getting this error message..."xml processing instruction not at start of external entity (error code 17), line 2, column 1...." pointing to the file of data (xml) I am trying to input.  If I pull up old data forms (from 2009) they work, but now I am getting this error.  I run Adobe Design Premium CS3 for Windows.  Can anyone tell me what to do to fix?

  • Error of type Not a known DirStatus - WGM throws error upon user creation

    Dear MacWorld,
    i run a OS-X 10.5.8 Server as OD-Master, clean install on MacPro, no migration, all updates applied, everything fresh from scratch, but my 2md installation of OS-X-server. All standard checks accomplished (Kerbreros, DNS, LDAP, ... everything fine so far).
    Each time i add a user in WGM (run remotely via ARD) i receive the errormessage
    "Got unexpected error
    Error of type Not a known DirStatus (-1) on line 2112 of /SourceCache/WorkgroupManager/WorkgroupManager-319.2.2/Plugins/UserAccounts/Use rAdvancedPluginView.mm"
    Makes me feel uncomfortable, although the resulting accounts look healthy so far. Since this is the last check before the final roll out of my OD in my organization, i'd like to get rid of it now rather then troubleshoot the OD later.
    Any hints?
    Cheers,
    my first post here!

    You seem to have your targetEntity mixed up, the @OneToMany should be B.class and @ManyToOne should be A.class.

  • Odata error: Parameters are not allowed for entity "calculationView" as it is not a calculation or analytical view

    I have created scripted calculation view
    I can add parameter in aforesaid calculation view
    It fetches me right result
    But when I am to call aforesaid calculation view from odata service I am getting following error:
    ERROR      zcustsearch/services/AutoComplete.xsodata
               Parameters are not allowed for entity "calculationView" as it is not a calculation or analytical view.
    Any solutions

    Don't reference it via the catalog object. Otherwise only the runtime Column View will be seen. Instead you should specific the view as the repository object.  This means no schema and use package path::view name.  Like this example from the SHINE content:
    service namespace "sap.hana.democontent.epmNext"  {
       "sap.hana.democontent.epmNext.models::CV_SALESORDER_YEAR_COMPARISON"
        as "salesYear" 
      keys generate local "ID"
        aggregates always
        parameters via entity "InputParams"; 

  • Error from reports from ZAM(Graph or PDF) - File does not begin with '%PDF-'.

    I just noticed today that any Graph or PDF report I try to view I get the
    following error - Error from reports from ZAM - File does not begin with
    '%PDF-'. I tried to just save the file and then open it, but get the same
    error. I can open other pdf files I have downloaded from other sites ok.
    Anyone have any idea? I haven't done anything to that server that I am
    aware of in quite a while.
    Thanks
    Bill

    I took a closer look at the files it downloaded, opened them with notepad,
    haer is what it says:
    XSL Transform or subsequent processing failedThe document has no pages.
    "Bill" <[email protected]> wrote in message
    news:2bBtk.2164$[email protected]..
    >I just noticed today that any Graph or PDF report I try to view I get the
    >following error - Error from reports from ZAM - File does not begin with
    >'%PDF-'. I tried to just save the file and then open it, but get the same
    >error. I can open other pdf files I have downloaded from other sites ok.
    >Anyone have any idea? I haven't done anything to that server that I am
    >aware of in quite a while.
    >
    > Thanks
    >
    > Bill
    >

  • HT201210 After downloading latest version of iTunes it will not open.  This error message is displayed;  The program can't star because MSVCR80.dll is missing from your computer.  Try reinstalling the program to fix this problem.  Then a second error box

    After iTunes requested that I download latest version on PC it now will not open.  2 error messages appear.  first:  The program can't start because MSVCR80.dll is missing from your computer.  Try reinstalling the program to fix this problem.  second:  iTunes was not installed correctly please reinstall iTunes. Error 7 (Windows error 126).  I have tried reinstalling a number of times and restarting computer but no luck.

    This happened to me today as well post installing the latest version of itunes.   I did a search on google for the error and came across a recommendation to :
    Note: Start Windows in Safe Mode to complete any of the following steps if you're unable to access Windows normally due to the msvcr80.dll error.
    If, and only if, you're receiving the msvcr80.dll is missing error when you open Apple iTunes, do the following: (skip this step if your msvcr80.dll error is occurring with a different program)
    Uninstall from Windows the following five programs in this order: iTunes, Apple Software Update, Apple Mobile Device Support, Bonjour, and finally Apple Application Support. If you have iCloud, remove it as well.
    Uninstalling these programs in Windows is done from an applet in Control Panel called Programs & Features (in Windows 8, 7, or Vista) or Add or Remove Programs (in Windows XP).
    Note: Songs and playlists in iTunes will not be removed when you uninstall the iTunes program or any of the other, already-mentioned Apple programs. If you'd still like to back them up, they're usually located in the My Music folder in Windows.
    Download the latest version of iTunes from Appleand note the location you're saving it to so you can find it once it's done.
    Run the iTunes installation as an administrator. If you're not sure how to do that, see How Do I Open an Elevated Command Prompt? for help. That procedure shows you how to open the Command Prompt program as an administrator, but the steps are essentially the same for anything, including the iTunes installation package you just downloaded.
    A general overview of removing and reinstalling iTunes can also be found here on Apple's site but the above procedure seems to work better in this particular situation.

  • Saving a Photoshop CC project from a Mac (in .PSD format) to a thumb drive and trying to transfer it to a Dell laptop with Photoshop CS6.  Will not open...Error message: could not complete your request because it is not a valid photoshop document.

    Saving a Photoshop CC project from a Mac (in .PSD format) to a thumb drive and trying to transfer it to a Dell laptop with Photoshop CS6.  Will not open...Error message: could not complete your request because it is not a valid photoshop document.

    The file was corrupted somewhere along the way (assuming it was still readable on the Macintosh).
    The platforms don't matter, but you still need file transfer that doesn't corrupt files...

  • I recently got a new iphone 4 w/iOs 7. I set up th eicloud, etc. and got my contacts and appointments from outlook. All was fine. Now it will not snyc/update my phone from outlook. I get "Your setup couldn't be started because of an unexpected error."

    I recently got a new iphone 4 w/iOs 7. I set up th eicloud, etc. and got my contacts and appointments from outlook. All was fine. Now it will not snyc/update my phone from outlook. I get "Your setup couldn't be started because of an unexpected error."

    Hello JinxUK,
    Thank you for the details of the issue you are experiencing with the iCloud Control Panel.  I found an article referencing the error message you are getting:
    “Your setup couldn't be started because of an unexpected error.”
    Apple is investigating this issue. This article will be updated as more information becomes available.
    iCloud: iCloud Control Panel setup cannot be started
    http://support.apple.com/kb/TS5178
    I recommend saving that link so that you can check back for a resolution when it becomes available. 
    Thank you for using Apple Support Communities.
    Best,
    Sheila M.

  • Error "page is not participating" while porting app from 10.1.2 to 10.1.3

    I have an old web application built using Struts 1.1 framework. I am trying to port this app from 10.1.2 to 10.1.3 OAS.
    The application is working fine on 10.1.2 for years but on porting to 10.1.3 application is working partially as some pages are are getting weird error as specified below.
    java.lang.IllegalStateException: page is not participating in session
         at com.evermind.server.http.EvermindPageContext.getAttribute(EvermindPageContext.java:643)
         at org.apache.struts.taglib.html.FormTag.initFormBean(FormTag.java:537)
         at org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:520)
         at _mytest._jspService(_mytest.java:333)I tried debugging the issue but could not find the root cause of the problem.
    Line 333 in error is where it's using struts-html form tag in jsp. The content of the page before this tag is displaying fine.
    <html:form name="MyTestForm"
                 method="post"
                 action="/test"
                 type="web.MyTestForm">The strange part is, other jsp's in application using the tag are working fine. Not sure why the error is occuring only on some pages.
    I have also checked the configuration, deployment setup, libraries, etc and all seems to be in place.
    I searched on web but found nothing except this somewhat related issue and tried the solution mentioned in this link http://www.velocityreviews.com/forums/t131230-struts-losing-session-after-jsp-page.html but in vain.
    (Not sure if this a Struts issue or OC4J issue so I am trying it on related forums)
    Any idea,help, suggestion, solution would be highly appreciated.
    Thanks

    JDeveloper 10.1.3 supports JDK 5.0.
    To run JDeveloper 10.1.2 applications in JDeveloper 10.1.3, set J2SE Version to 1.4.2 with Tools>Project Properties>Libraries>J2SE Version.

  • 'Document does not contain any items' error while posting GR from BAPI

    Hello Friends,
    I am trying to post GR from BAPI 'BAPI_GOODSMVT_CREATE' but some time it post successful and some time it does not post..gives error 'Document does not contain any items'....i have search all option but did not get any solution why this error is coming....kindly help me if you have any information regarding that.
    The strange thing is i have alrady posted GR with some test data and later on again am trying to post GR with same test data but it is giving error as above.
    For your information...i am using enhancement spot in standard program for GR posting...could it give any problem.
    Regards,
    Rajkishor.

    Solved by my self...problem was i were using enhancement spot in standard program because of this it was creating problem have search new enhancement spot and put my code out there now it is working fine.
    Thanku very much all of you for your reply.

  • I attempted to update my iphone5 to 7.1.1  There was an error and now my phone is erased.  I have attempted to restore from the cloud and it propogates the apple id with an old one, and will not allow me to restore from a the cloud

    I attempted to update my iphone5 to 7.1.1  There was an error and now my phone is erased.  I have attempted to restore from the cloud and it propogates the apple id with an old one, and will not allow me to restore from a the cloud

    Try:                                               
    - iOS: Not responding or does not turn on
    - Also try DFU mode after try recovery mode
    How to put iPod touch / iPhone into DFU mode « Karthik's scribblings
    - If not successful and you can't fully turn the iOS device fully off, let the battery fully drain. After charging for an least an hour try the above again.
    - Try another cable       
    - Try on another computer                            
    - If still not successful that usually indicates a hardware problem and an appointment at the Genius Bar of an Apple store is in order.
      Apple Retail Store - Genius Bar                              
    Also, do you remember what the error message said?

Maybe you are looking for

  • Batch generation for delivery creation

    Hi My client wants to process orders in background and have the batch create deliveries based on those orders.  For this reason I have created a variant via VL10A and have assigned the following under User Role.                                       

  • Not sure if i should use a database for my application?

    Hi Not sure if i should post here or not.. But my problem is that initially i planned to use a database to map my application logic so that it can keep information after the app shuts down and i would get it back the next session i open my app. My ap

  • Export Panel and Droplets

    After running a droplet through the Export Panel in Lightroom the action is not save to the image, whereas before the 'upgrade' it did, same action/droplet as before... Why is it not saving now?

  • CS4 Camera Raw - Starting Photoshop ?

    I have a PC with Win 7 64-bit. I have both the 3-2 and 64-bit versions of Photoshop CS4 installed. My NIK plug ins will not work with the 64-bit version of PS CS4 but work fine with the 32-bit version. However, when I double click on an image in CS4

  • IChat 3 AV and QT 7.0.2 performance issues...

    Right, here goes another strange one.. Upon upgrading to QT 7.0.2 I noticed that Video conferences in iChat 3 AV tend to hog the CPU so much more that video and audio keeps delaying and generally speaking, doing anything else with the system seems ne