User: ejort   
  Date: 02/02/09 08:09:24

  Modified:    src/main/org/jboss/ejb/plugins/jaws/jdbc
                        JDBCInitCommand.java
  Log:
  Guarded info logging. Faster when not interested in life-cycle logging
  
  Revision  Changes    Path
  1.19      +6 -3      
jboss/src/main/org/jboss/ejb/plugins/jaws/jdbc/JDBCInitCommand.java
  
  Index: JDBCInitCommand.java
  ===================================================================
  RCS file: 
/cvsroot/jboss/jboss/src/main/org/jboss/ejb/plugins/jaws/jdbc/JDBCInitCommand.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- JDBCInitCommand.java      12 Jan 2002 21:14:27 -0000      1.18
  +++ JDBCInitCommand.java      9 Feb 2002 16:09:24 -0000       1.19
  @@ -33,7 +33,7 @@
    * @author <a href="mailto:[EMAIL PROTECTED]";>David Jencks</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>danch (Dan Christopherson</a>
    * 
  - * @version $Revision: 1.18 $
  + * @version $Revision: 1.19 $
    * 
    *   <p><b>Revisions:</b>
    *
  @@ -137,8 +137,10 @@
            }
   
            // Try to create it
  +         boolean infoEnabled = log.isInfoEnabled();
            if(created) {
  -             log.info("Table '"+jawsEntity.getTableName()+"' already exists");
  +             if (infoEnabled)
  +                 log.info("Table '"+jawsEntity.getTableName()+"' already exists");
            } else {
                try
                {
  @@ -148,7 +150,8 @@
                   factory.getContainer().getTransactionManager().commit ();
   
                   // Create successful, log this
  -                log.info("Created table '"+jawsEntity.getTableName()+"' 
successfully.");
  +                if (infoEnabled)
  +                    log.info("Created table '"+jawsEntity.getTableName()+"' 
successfully.");
                     if (jawsEntity.getPrimKeyField() != null)
                       if (debug)
                       log.debug("Primary key of table '"+jawsEntity.getTableName()+"' 
is '"
  
  
  

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

Reply via email to