EJB design: What are the advantages of EJB compared to Servlets
1. When we can do everything using Servlets, Why and when
should,one go for EJB.   2. I am new to j2ee but from what I
have read and developed I believe that EJB's offer more advanced
scalability features (object passivation/activation for beans,
caching for entity (data) beans, etc). They also offer
transaction & security features with out a need to program to
any specific API (such as JTA). Data access can be easier using
Entity Beans vs using jdbc.     A question I would like answered
is has any body out there compared the scalablilty of an
application that uses stateful sesion beans versus a servlet
that holds it's state in a regular java object stored in an
httpSession. I would think that Session beans would scale
better, but maybe they don't because of all the
transaction/security overhead. Any comments from anyone?   3. if
you look at the discussion below for stateless vs helper class i
found it useful    4. EJB and sevlets cannot be co