3 Replies Latest reply on Jul 5, 2002 5:59 AM by vvinjamur

    [b]EJB2.0 entity bean must not be an abstract class?!!![/b]

    vvinjamur

      Hi,

      please suggest


      I am trying deploy an example application for CMP

      as it is mentioned that the container will implement the entity class and we need to make the entitybean class as an abstract class i did the same but to my frustration while deplying it is giving the following warning
      **********************************************************
      Bean : ProductEBean
      Section: 9.2.2
      Warning: The entity bean class must not be defined as abstract.

      16:41:59,031 INFO [EJBDeployer]
      Bean : ProductEBean
      Section: 9.4.7.1
      Warning: The primkey-field element must name a public field in the bean implementation class.

      ********************************************************
      and at run time it gives an exceptoin like this:
      *********************************************************

      17:00:43,359 ERROR [STDERR] java.rmi.ServerException: Could not instantiate bean; nested exception i
      s:
      java.lang.InstantiationException: examples.ejb.ProductEBean; nested exception is:
      java.rmi.ServerException: Could not instantiate bean; nested exception is:
      java.lang.InstantiationException: examples.ejb.ProductEBean
      17:00:43,359 ERROR [STDERR] java.rmi.ServerException: Could not instantiate bean; nested exception i
      s:
      java.lang.InstantiationException: examples.ejb.ProductEBean

      **********************************************************

      I am clue less as to why is saying as the class must not be abstract even though i mentioned

      <persitence type> as Container in ejb-jar xml

      please help