18.3. JCA resource adapters: rationale and principles

Using EJBs to interact with external resources via socket connections and the like has a number of complications.

  • The external resource may be limited in the number of clients it can support, for technical or pragmatic reasons. In this example, the quote server may be a subscription service, charged per concurrent connection. Concurrent access to the server may be required by many instances of a number of different EJBs. Some legacy systems may even be single-threaded and support only one connection at a time.

  • Even if connection concurrency is not, in itself, a problem, setting up the socket connection is a costly operation, particularly if the external resource is not part of the same network ...

Get Applied Enterprise JavaBeans™ Technology 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.