• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Jesse Silverman
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Frits Walraven

Confusion on ejbHome,ejbFind and ejbSelect methods!

 
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi folks,
i have a very hard time understanding the way these ejbHome, ejbFind and ejbSelect methods in *pooled* state. It's stated that an instance of an entity bean is not associated with any particular client in this (*pooled*) state. however, these methods can be run in that state. my question is that who ( a client) these methods are working for? if an instance of any entity bean is not associated with any client, who these methods are associated with and working for? could you please eplain me this?
thanks.
[ December 29, 2003: Message edited by: Tulsi Rai ]
 
Bartender
Posts: 1872
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Tulsi,

It's stated that an instance of an entity bean is not associated with any particular client in this (*pooled*) state.


Where did you read that ?
Entity beans in the pool have no id : no EJBObject and no primary key. But when they run a method in the pooled state (ejbHome*()) (OK + ejbFind*() and ejbSelect*() called from home business methods, but it's not your business ), they *know* for which client they are working (ctx.getCallerPrincipal() and ctx.isCallerInRole() can be called).
I just remembered in that lifecycle what's important to know from the bean provider's point of view :

(*) Other methods are ejbPostCreate*(), ejbLoad(), ejbStore() and business methods.
Best,
Phil.
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic