Header Ads

  • Breaking Now

    What are new features of EJB3?

    EJB2.x used to be a too complex technology for developers so in EJB 3 a lot has been done to simplify things for end users of the technology and moreover give EJB a new lease of life.In latest edition of EJB the following features have been included:

    -Support for Annotations.e.g. the EJB2 callbacks ( such as the ejbActivate() method) are now defined using annotation. For the ejbActivate() method, this is done with the help of @PostActivate annotation. This annotation is set on a method that will be called by the container.Or to define a stateless session bean, the @Stateless annotation is declared on the bean class.

    -Introducing 'Business Interceptors' which allows a developer to intercept each business method of a bean.These interceptors are chained and values of parameters and return values can always be changed.

    -Persistence in EJB3.0 is majorly simplified by using EntityManager persistence API.The Entity Beans are POJO objects and support inheritance too.It is very similar to Hibernate,JDO

    Post Top Ad

    Post Bottom Ad