User: user57  
  Date: 02/02/16 03:27:00

  Modified:    src/main/org/jboss/test/cts/interfaces
                        UserTransactionTester.java
  Log:
   o System.err, System.out & printStackTrace() 99.9% gone.
  
  Revision  Changes    Path
  1.2       +14 -11    
jbosstest/src/main/org/jboss/test/cts/interfaces/UserTransactionTester.java
  
  Index: UserTransactionTester.java
  ===================================================================
  RCS file: 
/cvsroot/jboss/jbosstest/src/main/org/jboss/test/cts/interfaces/UserTransactionTester.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- UserTransactionTester.java        29 Apr 2001 08:04:58 -0000      1.1
  +++ UserTransactionTester.java        16 Feb 2002 11:27:00 -0000      1.2
  @@ -17,10 +17,13 @@
    *  This does not depend on JUnit, as JUnit is not available on the server.
    *
    *  @author <a href="mailto:[EMAIL PROTECTED]";>Ole Husgaard</a>
  - *  @version $Revision: 1.1 $
  + *  @version $Revision: 1.2 $
    */
   public class UserTransactionTester
   {
  +   static org.apache.log4j.Category log =
  +      org.apache.log4j.Category.getInstance(UserTransactionTester.class);
  +
      /**
       *  Home of entity used as a resource for testing.
       */
  @@ -70,7 +73,7 @@
         try {
            bean1 = home.create(new AccountPK("UT_TestBean1"), "Ole1");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
   
  @@ -98,7 +101,7 @@
            if (!gotException)
               throw new RuntimeException("Rollback didn't rollback create.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
   
  @@ -106,7 +109,7 @@
         try {
            bean2 = home.create(new AccountPK("UT_TestBean2"), "Ole2");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
   
  @@ -134,7 +137,7 @@
            if (ut.getStatus() != Status.STATUS_NO_TRANSACTION)
               throw new RuntimeException("No tx should be active.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
         return true;
  @@ -157,7 +160,7 @@
            if (ut.getStatus() != Status.STATUS_NO_TRANSACTION)
               throw new RuntimeException("No tx should be active.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
         return true;
  @@ -183,7 +186,7 @@
            if (ut.getStatus() != Status.STATUS_NO_TRANSACTION)
               throw new RuntimeException("No tx should be active.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
         return true;
  @@ -217,7 +220,7 @@
            if (ut.getStatus() != Status.STATUS_NO_TRANSACTION)
               throw new RuntimeException("No tx should be active.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
         return true;
  @@ -259,7 +262,7 @@
            if (ut.getStatus() != Status.STATUS_NO_TRANSACTION)
               throw new RuntimeException("No tx should be active.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
         return true;
  @@ -296,7 +299,7 @@
            if (ut.getStatus() != Status.STATUS_NO_TRANSACTION)
               throw new RuntimeException("No tx should be active.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
         return true;
  @@ -344,7 +347,7 @@
            if (ut.getStatus() != Status.STATUS_NO_TRANSACTION)
               throw new RuntimeException("No tx should be active.");
         } catch (Exception ex) {
  -         ex.printStackTrace();
  +         log.debug("failed", ex);
            return false;
         }
         return true;
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to