[seam-commits] Seam SVN: r10114 - trunk/doc/Seam_Reference_Guide/en-US.

seam-commits at lists.jboss.org seam-commits at lists.jboss.org
Tue Mar 3 22:48:44 EST 2009


Author: shane.bryzak at jboss.com
Date: 2009-03-03 22:48:43 -0500 (Tue, 03 Mar 2009)
New Revision: 10114

Modified:
   trunk/doc/Seam_Reference_Guide/en-US/Remoting.xml
Log:
Added note about transactional remoting requests

Modified: trunk/doc/Seam_Reference_Guide/en-US/Remoting.xml
===================================================================
--- trunk/doc/Seam_Reference_Guide/en-US/Remoting.xml	2009-03-03 21:15:58 UTC (rev 10113)
+++ trunk/doc/Seam_Reference_Guide/en-US/Remoting.xml	2009-03-04 03:48:43 UTC (rev 10114)
@@ -693,6 +693,21 @@
     </section>
 
   </section>
+  
+  <section>
+    <title>Transactional Requests</title>
+    
+    <para>
+      By default there is no active transaction during a remoting request, so if you wish to perform database updates 
+      during a remoting request, you need to annotate the <literal>@WebRemote</literal> method with 
+      <literal>@Transactional</literal>, like so:
+    </para>
+    
+    <programlisting><![CDATA[  @WebRemote @Transactional(TransactionPropagationType.REQUIRED)
+  public void updateOrder(Order order) {
+    entityManager.merge(order);
+  }]]></programlisting>
+  </section>
 
   <section>
     <title>JMS Messaging</title>




More information about the seam-commits mailing list