Harvinder Singh wrote:
> Hi,
> EJB1.1 Specs say, "The transaction-type element is not supported for entity
> beans because all entity beans must use container-managed-transaction
> demarcation." Could any body elaborate upon this point.
>
> Regards,
> Harvinder
Bean managed transaction demarcation is accomplished using the
UserTransaction object. The UserTranaction interface has methods such as
begin() and commit().
A bean gets a UserTranaction object from its context object. However,
only session beans with a transaction-type of Bean in the deployment
descriptor can invoke getUserTransaction() on their context object
without getting an exception.
Every other bean, that is, all entity beans and all session beans with a
transaction-type of Container, rely on the container for transaction
demarcation. For these beans, a trans-attribute in the deployment
descriptor such as Required, Supports, etc. tells the container when the
begin and commit the transaction.
Hope this helps.
Vance Christiaanse
===========================================================================
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".