3 Replies Latest reply on Nov 3, 2005 6:52 AM by kabirkhan

    Lifecycle methods in abstract classes

      Hi,

      When I use an abstract base class for a bean, and I put life cycle callback methods in the abstract class, they are not being called by the container. Is this behaviour intentional / according to the specs? I did not find anything in the specs relating a class hierarchy of beans.

      @MessageDriven
      public abstract class BaseBean {
       @PostConstruct
       public void init() {
       System.out.println("Hello world");
       }
      }
      
      @MessageDriven
      public class MyBean extends BaseBean {
      
      }