Win a copy of JDBC Workbook this week in the JDBC and Relational Databases forum
or A Day in Code in the A Day in Code forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
  • Piet Souris
  • salvin francis
  • fred rosenberger

Pooling of EJBHome and Remote objects

Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does the container pool EJB Home and Remote objects? What are the pros/cons of using POJO helper classes within my EJB? can I start/stop transactions within my helper classes?
Ranch Hand
Posts: 93
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It is the responsibility of a developer to cache/pool EJBHomes. Pooling remote references is not always feasible, unlike homes (consider entities and SFSBs). The container may pool the concrete implementations of your interfaces, but those are considered internal plumbing and shouldn't be of concern for you as a developer.
If you are still interested in the subject, I recommend you look into the ServiceLocator pattern. You might want to take a look at Sun's blueprints - Petstore and Adventure Builder applications, which use these technics. This strategy is mostly considered to be applicable to clients of EJB application, but there are options to use it in the EJB server as well, though it involves some tricks on your side.
Generally, this topic is outta scope of SCBCD exam, but you might want to study it later on your own if you want to be an effective (and well-paid ) EJB developer.
I yam what I yam and that's all that I yam - the great philosopher Popeye. Tiny ad:
Thread Boost feature
    Bookmark Topic Watch Topic
  • New Topic