O'Reilly logo

NetBeans IDE 8 Cookbook by Rhawi Dantas, David Salter

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating an EJB

Enterprise Java Beans (EJBs) are server-side managed classes intended to provide business functionality to applications. Since Java EE 5, EJBs have been made much simpler and more lightweight.

EJBs no longer have to be defined by XML descriptors, but are defined using Java annotations instead. This allows EJBs to be developed more quickly and probably more importantly, to be fully testable outside of the application server.

In Java EE 7, there are four types of EJB. They are Stateless, Stateful, Singleton, and Message Driven EJBs. J2EE also had Entity beans used for modeling data, but these have been deprecated since Java EE 5 to be replaced with POJOs and JPA.

Stateless EJBs, as their name suggest, maintain no state. When a request ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required