I cannot tell from your description whether the entity bean method's transaction
attribute is tx_supports. If it is, then JBoss should be throwing an exception
since setRollbackOnly isn't valid in this context.

--Victor

Michael Jara wrote:

> FYI: I took a clue from bug #420714 an tried moving my "setRollbackOnly" to
> a session bean.  I was doing something like this before in my entity bean:
>
> this.entityContext.setRollbackOnly();
> throw new StorageSynchronizationException(); // my application exception
>
> I changed the entity bean:
>
> // this.entityContext.setRollbackOnly();
> throw new StorageSynchronizationException(); // my application exception
>
> And I added to the the stateful session bean which was calling the entity
> bean:
>
> ...
> catch(StorageSynchronizationException ex)
> {
>   this.sessionContext.setRollbackOnly();
>   throw ex;
> }
>
> This works correctly!  The problem appears to be specific to entity beans.
> Nevertheless, it is still a problem, but at least I have a better
> workaround.
>
> Mike
>


_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to