Exposing RESTful Services through JAX-RS

At this point we need to create a Stateless Session Bean (EJB) that will query exhibition data through the JPA entities and return such information. Before getting into it, let's take a quick look at the types of beans supported by Java EE 6 and their definitions:

  • Stateless: This is the same definition we find for EJB 2.x—components that aren't supposed to keep information between calls. The container keeps a bean pool, and any bean instance can serve an incoming request, being very lightweight to keep and having good scalability due to its ability to serve multiple clients.
  • Stateful: When multiple interactions between system and user is needed, this kind of bean keeps consistent state through the conversation. ...

Get Getting Started with Oracle WebLogic Server 12c: Developer's Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.