3 Replies Latest reply on Nov 10, 2004 10:26 AM by starksm64

    Unexpected transaction retries

    jesper6tv

      Im using JBoss 3.2.5.
      I have a problem with a SLSB, where in some cases, a call to one of its method is performed twice, that is the transaction is apparently being retried, without any Exception being thrown. No deadlock is being reported.
      Is this a feature or a bug?
      Does JBoss transaction management retry a transaction in case of resource timeout, or to serialize transactions?

      Regards
      Jesper

        • 1. Re: Unexpected transaction retries
          starksm64

          There is retry logic on application deadlock detection. The retry attempt is logged at debug level. See the org.jboss.ejb.plugins.TxInterceptorCMT code.

          • 2. Re: Unexpected transaction retries
            jesper6tv

            Thanks for the quick answer. That explains my problems.

            Will it be possible in a later release of JBoss (4.0?) to assign different MAX_RETRIES on a per Bean basis?

            -Jesper

            • 3. Re: Unexpected transaction retries
              starksm64

              Create an RFE for that on sourceforge.

              You can disable retries by specifiying a org.jboss.ejb.plugins.TxRetryExceptionHandler implementation in the container configuration in either the jboss.xml or standardjboss.xml

              <jboss>
              ...
               <container-configurations>
              
               <container-configuration extends="Standard Stateless SessionBean">
               <container-name>Retry</container-name>
               <container-interceptors>
               <interceptor>org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor</interceptor>
               <interceptor>org.jboss.ejb.plugins.LogInterceptor</interceptor>
               <interceptor>org.jboss.ejb.plugins.SecurityInterceptor</interceptor>
               <!-- CMT -->
               <interceptor transaction="Container">org.jboss.ejb.plugins.TxInterceptorCMT
               <retry-handlers>
               <handler>org.jboss.test.retry.interfaces.RetryHandler</handler>
               </retry-handlers>
               </interceptor>
              ...