We have an application where every 5 minutes an a4j:poll queries to see if there are any
user alerts to display. If there is an alert, the user is presented with a modal dialog.
They then click an OK button on the dialog which causes the Alert to save to the database
with the acknowledgment time.
This alert dialog can be displayed on any screen in the application, but the alert
acknowledgment action should not participate in those screen's transactions.
It works great in every scenario except for the following: The user is on an edit screen
and is making changes. A new alert modal dialog is displayed and the user clicks OK. The
alert acknowledgment time is saved, but so are the user's changes on the edit screen.
This is not good.
The alert action is a Stateful EJB.
I have tried numerous ways to get this to occur how I want using
@TransactionAttribute.NOT_SUPPORTED, REQUIRES_NEW, but I just cannot get it to work.
When the form posts and the acknowledge alert action is called, is it possible that the
form values for the edit screen are also being applied to this new "nested"
transaction or is the transaction demarcation not really occurring like I think it is?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4041932#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...