Good Morning and please give the answers to my below questions.
i) Which type of bean will survive a container / server crash? why?
ii) When a "stateful session bean" "times out", after being in the "passivated" state, will the container invoke any "call back"(esp. ejbRemove()) method?
posted 10 years ago
Hey, Hope I can help!
i- Entity Beans will survive a container crash. After all they're persisted in a database. And the data will still be there, unless you execute a DELETE against it
ii- No. For the container to call any callback method, it would have to first activate the instance. And there is no sense in activating a instance just to tell it's dead. You better have your clean-up code in both ejbRemove() and ejbPassivate()