1 Reply Latest reply on Nov 26, 2006 1:31 PM by ganton516

    PersistenceException on GeneratedValue property

      I am running on JBoss 4.0.5 with the EJB3 install

      I have a stateless EJB that persists entities (POJOs) to a MySQL db (5.x).

      When I first deploy the EJB, entities insert,update and delete just fine. However, if I make a modification to the EJB, and re-deploy it, I get:

      javax.persistence.PersistenceException: org.hibernate.PropertyAccessException: IllegalArgumentException occurred
      calling getter of com.company.entity.EntityBean.EntityId
      


      EntityId is a GeneratedValue field of EntityBean

      My thought here, is that the EJB3 persistence engine is "loosing track" of the unique id value for EntityId, upon re-deployment, and thus cannot perform the insert.

      Is there anyway around this ? (Custom Id Generator)



        • 1. Re: PersistenceException on GeneratedValue property

          This turns out to be a class loading issue.

          Due to the complex nature of the architecture I am attempting to build. When the "new" versions of the entities are hot deployed the persistence engine apparently gets confused, and refuses to cooperate.

          If this sounds like a problem you are having as well, please contact me, and I can explain the issue farther, and how I got around it.