Hey
This was rather confusing...
Nittle Gupta wrote:
> >1. a bean instance (session and entity) has a own remote class?
> Ans. Yes.
This is implementation specific, i.e. yes and no.
> >2. all instances of a bean share the same instance of home class or an
> >instance has a own home class?
> Ans. an instance has a own home class
Incorrect, all instances of a bean share the same instance of home
class.
> >3. What are the advantages in keeping session with session bean and EJB
> >instead of Session Tracking and Servlet?
> Ans. EJBeans have the business transactional behaviour.
Incorrect, servlets may have transactional behaviour as well (through
explicit demarcation).
* Minimal movement of data between application model and GUI
(servlet=GUI in this case)
* Automatic transactions
* Session beans are more scalable since they can be passivated to
secondary storage. Servlets have no such functionality
(activation/passivation), although it would be possible to do a
properietary solution to get around this.
> >4. What are the advantages in using bean-managed transaction instead of
> >container-managed ones?
> Ans. Less transactional overheads.
Automatic transactions are very good to use as they are
easier to code. You *will* get it wrong when doing it by yourself.
> >5. Does J2ee function as Web server or is it necessary to install Java
> >Web Server or Apache?
> Ans. No J2EE provides a reference EJB server .U have to use web server.
Incorrect. A webserver is builtin, and default port is 8000.
> >7. Is it true that an entity bean is compelled to use container-managed
> >transaction? Why?
> Yes.
It is easier. And in EJB1.1 this is also the only possibility as
bean-managed
transactions have been removed for Entities.
> >8. May I defini a session bean that has an entity bean as its own field
> No.
Incorrect. Yes, you may. Additionally, if you have a stateful session
bean, EJB1.1 explicitly states in section 6.4.1 that this is legal and
that the container will handle activation/passivation transparently for
you.
I hope this clears some of the (apparent) confusion. Nittle, do your
homework better next time ;-)
/Rickard
--
Rickard �berg
@home: +46 13 177937
Email: [EMAIL PROTECTED]
Homepage: http://www-und.ida.liu.se/~ricob684
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".