[jboss-cvs] JBossCache/src/org/jboss/cache/interceptors ...

Manik Surtani msurtani at jboss.com
Wed Feb 28 13:22:54 EST 2007


  User: msurtani
  Date: 07/02/28 13:22:54

  Modified:    src/org/jboss/cache/interceptors   TxInterceptor.java
                        InvalidationInterceptor.java
  Log:
  JBCACHE-979
  
  Revision  Changes    Path
  1.79      +17 -3     JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java,v
  retrieving revision 1.78
  retrieving revision 1.79
  diff -u -b -r1.78 -r1.79
  --- TxInterceptor.java	27 Feb 2007 21:57:36 -0000	1.78
  +++ TxInterceptor.java	28 Feb 2007 18:22:54 -0000	1.79
  @@ -507,6 +507,9 @@
               }
               if (retval != null && retval instanceof Exception)
               {
  +               if (retval instanceof RuntimeException)
  +                  throw (RuntimeException) retval;
  +               else
                  throw new RuntimeException((Exception) retval);
               }
            }
  @@ -707,11 +710,19 @@
            {
               cleanupStaleLocks(gtx);
            }
  +         catch (RuntimeException re)
  +         {
  +            log.error("Unable to clear stale locks", re);
  +            throw re;
  +         }
            catch (Throwable e2)
            {
               log.error("Unable to clear stale locks", e2);
               throw new RuntimeException(e2);
            }
  +         if (e instanceof RuntimeException)
  +            throw (RuntimeException) e;
  +         else
            throw new RuntimeException("Commit failed.", e);
         }
      }
  @@ -1081,6 +1092,9 @@
               {
                  throw new RuntimeException("setting tx rollback failed ", se);
               }
  +            if (t instanceof RuntimeException)
  +               throw (RuntimeException) t;
  +            else
               throw new RuntimeException("", t);
            }
            finally
  
  
  
  1.31      +4 -1      JBossCache/src/org/jboss/cache/interceptors/InvalidationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvalidationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/InvalidationInterceptor.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- InvalidationInterceptor.java	7 Feb 2007 22:06:40 -0000	1.30
  +++ InvalidationInterceptor.java	28 Feb 2007 18:22:54 -0000	1.31
  @@ -117,6 +117,9 @@
                           {
                              throw new RuntimeException("setting tx rollback failed ", se);
                           }
  +                        if (t instanceof RuntimeException)
  +                           throw t;
  +                        else
                           throw new RuntimeException("Unable to broadcast invalidation messages", t);
                        }
                     }
  
  
  



More information about the jboss-cvs-commits mailing list