User: patriot1burke Date: 02/04/09 22:42:38 Modified: src/main/org/jboss/ejb/plugins EntityInstanceInterceptor.java Log: don't ctx.setTransaction is method is readonly or bean is readonly. Otherwise, Passivation thread could spin forever Revision Changes Path 1.52 +8 -2 jboss/src/main/org/jboss/ejb/plugins/EntityInstanceInterceptor.java Index: EntityInstanceInterceptor.java =================================================================== RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/ejb/plugins/EntityInstanceInterceptor.java,v retrieving revision 1.51 retrieving revision 1.52 diff -u -r1.51 -r1.52 --- EntityInstanceInterceptor.java 8 Mar 2002 08:12:45 -0000 1.51 +++ EntityInstanceInterceptor.java 10 Apr 2002 05:42:38 -0000 1.52 @@ -40,7 +40,7 @@ * @author <a href="mailto:[EMAIL PROTECTED]">Marc Fleury</a> * @author <a href="mailto:[EMAIL PROTECTED]">Scott Stark</a> * @author <a href="mailto:[EMAIL PROTECTED]">Bill Burke</a> -* @version $Revision: 1.51 $ +* @version $Revision: 1.52 $ * * <p><b>Revisions:</b><br> * <p><b>2001/06/28: marcf</b> @@ -172,7 +172,13 @@ // Associate transaction, in the new design the lock already has the transaction from the // previous interceptor - ctx.setTransaction(mi.getTransaction()); + + // Don't set the transction if a read-only method. With a read-only method, the ctx can be shared + // between multiple transactions. + if (!container.isReadOnly() && !container.getBeanMetaData().isMethodReadOnly(mi.getMethod().getName())) + { + ctx.setTransaction(mi.getTransaction()); + } // Set the current security information ctx.setPrincipal(mi.getPrincipal());
_______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development