O'Reilly logo

Enterprise JavaBeans 3.1, 6th Edition by Bill Burke, Andrew Lee Rubinger

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

Chapter 3. Container Services

We see examples of efficient processes every day, even in our most mundane daily routines. A trip to the supermarket may involve ordering sliced meats from the deli counter, selecting grocery items from pre-stacked shelves, listening to advice from the butcher, and paying the cashier. If we were to model this errand as a business system, we’d notice that the whole is composed of many smaller pieces, and each task is serviced by a specialized worker. It is this same “do one thing and do it well”[4] approach that was introduced in French firearms production, powered the assembly lines pioneered by Henry Ford, and became omnipresent during the American industrial revolution as the preferred mechanism to maximize throughput.

The benefits of allowing each concern to be fulfilled by a specialist through division of labor are fairly obvious: a secretary should answer phones while a mail room attendant handles shipping. Similarly, application developers should write the rules of their business and leave the mechanics of reliable, distributed systems to middleware providers.

In the case of EJB, the Component Model defines our interchangeable parts, and the Container Services are specialists that perform work upon them. The Specification provides:

  • Dependency injection

  • Concurrency

  • Instance pooling/caching

  • Transactions

  • Security

  • Timers

  • Naming and object stores

  • Interoperability

  • Lifecycle callbacks

  • Interceptors

  • Java Enterprise Platform integration

We’ll introduce each at a high ...

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