What are the call back methods in Session bean?
-
ejbCreate()
-
ejbPassivate(),
-
ejbActivate()
-
All the above
D
Correct answer
Explanation
Session beans have callback methods that the container invokes at specific lifecycle points. ejbCreate() is called when a bean instance is created. ejbActivate() is called when a passivated bean is activated (moved from secondary storage to memory). ejbPassivate() is called when a stateful session bean is passivated (moved to secondary storage to conserve resources). All three are valid callback methods.