Michael Pikounis wrote:

 > I have the following problem when using the remove() method of a bean
 > managed entity bean:
 >
 > step 1: call bean.remove() to remove the bean
 > step 2: call Enumeration i = home.findBySomeCriterion( criteria )
 >
 > my enumeration contains the bean I removed, because (I think) weblogic does
 > not call ejbRemove until the end of the transaction! Anyone knows of a way
 > to force weblogic (4.5.1) to call ejbRemove immediately (when I call
 > bean.remove()) rathen than wait until the end of the transaction?
 >
 > Alternatively, is there a way to tell weblogic to filter out "deleted" beans
 > when it builds the enumeration from the finder method?

Take a look at the delayUpdatesUntilEndOfTx setting in the
deployment descriptor.  Setting it false causes stores and
removes to be made (within the transaction, but not committed)
when the EJB method completes, rather than at the end of the
transaction.  I know it fixes your finder issue for updates,
but I've never checked if it works for removes.  Just be
careful because any other beans set to pick up uncommitted
reads will also see it now (you probably want TX_SERIALIZABLE
on everything).

-Paul Hodgetts

===========================================================================
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".

Reply via email to