On Tue, Jun 23, 2009 at 11:40 AM, Ted Goddard <ted.goddard@icesoft.com> wrote:

ICEfaces doesn't alter the lifecycle from the point of view of
validation -- our purpose there was to make Ajax development and
non-Ajax development as similar as possible.  The submit action is
where we typically recommend putting the database commit.

Just the clarify (not countering your statement), with JPA you often don't get to choose when the database is updated. That's something that JPA decides based on the flush mode. In standard JPA, this happens at least when the transaction commits (FlushMode.COMMIT) or sooner (FlushMode.AUTO). So it's more that the developer has to be conscious of whether a commit will happen, even in the absense of an explicit commit in the code.

The technical details of this problem could be debated for days. If we want to avoid going down that slippery path, we should discuss whether it is worth introducing the concept of "skip update model".

-Dan

--
Dan Allen
Senior Software Engineer, Red Hat | Author of Seam in Action

http://mojavelinux.com
http://mojavelinux.com/seaminaction
http://in.relation.to/Bloggers/Dan

NOTE: While I make a strong effort to keep up with my email on a daily
basis, personal or other work matters can sometimes keep me away
from my email. If you contact me, but don't hear back for more than a week,
it is very likely that I am excessively backlogged or the message was
caught in the spam filters.  Please don't hesitate to resend a message if
you feel that it did not reach my attention.