Q. Explain which bean is faster than other(Stateless/Statefull) and why?
Ans: State full bean has to be persisted while stateless is only used once. If cluster is used, State full Session Bean has to be replicated on all servers. State full Session Bean has to be tied to session and used for that session only, while State Less Session Bean is used for single request only.
But, State less and State full have different usages. If you are building request response application State less is OK. If you have app that has to remember state between multiple requests, State full is the option.
No comments:
Post a Comment