This week's book giveaway is in the OCP forum. We're giving away four copies of OCP Oracle Certified Professional Java SE 11 Developer Practice Tests and have Scott Selikoff and Jeanne Boyarsky on-line! See this thread for details.
All..... My question is for using the statless container managed Is there is any need to call the ejbRemove() method will it be explicitly called for the Conatainer managed Bean Once after creating an instance of it.
What happens Should i call the ejbRemove() method every time i create an instance for an Bean Managed EJB to return the instance to the pool or it will be the same as with the Container managed EJB
I'm new to EJBs, so could someone please explain to me why a stateless session bean would be either BMP or CMP? The P stands for persistence, right? What's there to persist in a stateless session bean? Or even a stateful one for that matter - the "state" is similar to the session attribute scope, isn't it?
hi if u call ejbRemove() it has no effect on stateless session bean... after each business call the bean automatically returns to the pool... so no use in calling it and the container wont bother.
in stateful session... ur call to ejbRemove() results in the execution of the code there(like resource release) and the bean getting destroyed... so u do need to call ejbRemove() for the stateless beans.
The CMP and BMP of entity bean is entirely different from this... there calling ejbRemove() results in the deletion of the entity in the underlying data store.