You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by bu...@apache.org on 2002/07/24 20:01:09 UTC

cvs commit: xml-axis/java/src/org/apache/axis/providers/java EJBProvider.java JavaProvider.java

butek       2002/07/24 11:01:07

  Modified:    java/src log4j.properties
               java/src/org/apache/axis Constants.java
                        FaultableHandler.java
               java/src/org/apache/axis/client Call.java
               java/src/org/apache/axis/handlers JWSProcessor.java
               java/src/org/apache/axis/providers/java EJBProvider.java
                        JavaProvider.java
  Log:
  I don't know about the rest of you, but I've gotten fed up with the overflow
  of build output.  So I've implemented the enterprise logging category, as we
  discussed last week, on the biggest offenders of useless output:  the
  "Mapping exception to AxisFault" stack dumps.
  
  Revision  Changes    Path
  1.7       +4 -1      xml-axis/java/src/log4j.properties
  
  Index: log4j.properties
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/log4j.properties,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- log4j.properties	27 Feb 2002 20:31:09 -0000	1.6
  +++ log4j.properties	24 Jul 2002 18:01:03 -0000	1.7
  @@ -1,6 +1,9 @@
  -# Set root category priority to ERROR and its only appender to A1.
  +# Set root category priority to INFO and its only appender to CONSOLE.
   log4j.rootCategory=INFO, CONSOLE
   #log4j.rootCategory=INFO, CONSOLE, LOGFILE
  +
  +# Set the enterprise logger category to FATAL and its only appender to CONSOLE.
  +log4j.logger.org.apache.axis.enterprise=FATAL, CONSOLE
   
   # CONSOLE is set to be a ConsoleAppender using a PatternLayout.
   log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
  
  
  
  1.73      +6 -0      xml-axis/java/src/org/apache/axis/Constants.java
  
  Index: Constants.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/Constants.java,v
  retrieving revision 1.72
  retrieving revision 1.73
  diff -u -r1.72 -r1.73
  --- Constants.java	24 Jul 2002 12:25:36 -0000	1.72
  +++ Constants.java	24 Jul 2002 18:01:04 -0000	1.73
  @@ -105,6 +105,12 @@
           URI_SOAP12_ENV,
       };
   
  +    // Constant name of the enterprise-style logging category.
  +    // The enterprise category is for stuff that an enterprise product might
  +    // want to track, but in a simple environment (like the AXIS build) would
  +    // be nothing more than a nuisance.
  +    public static final String ENTERPRISE_LOG_CATEGORY = "org.apache.axis.enterprise";
  +
       /**
        * Returns true if SOAP_ENV Namespace
        */
  
  
  
  1.41      +7 -1      xml-axis/java/src/org/apache/axis/FaultableHandler.java
  
  Index: FaultableHandler.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/FaultableHandler.java,v
  retrieving revision 1.40
  retrieving revision 1.41
  diff -u -r1.40 -r1.41
  --- FaultableHandler.java	3 Jul 2002 17:50:30 -0000	1.40
  +++ FaultableHandler.java	24 Jul 2002 18:01:04 -0000	1.41
  @@ -78,6 +78,12 @@
       protected static Log log =
           LogFactory.getLog(FaultableHandler.class.getName());
   
  +    // The enterprise category is for stuff that an enterprise product might
  +    // want to track, but in a simple environment (like the AXIS build) would
  +    // be nothing more than a nuisance.
  +    protected static Log entLog =
  +        LogFactory.getLog(Constants.ENTERPRISE_LOG_CATEGORY);
  +
       protected Handler    workHandler ;
   
       /** Constructor
  @@ -109,7 +115,7 @@
               workHandler.invoke( msgContext );
           }
           catch( Exception e ) {
  -            log.info(JavaUtils.getMessage("toAxisFault00"), e );
  +            entLog.info(JavaUtils.getMessage("toAxisFault00"), e );
               AxisFault fault = AxisFault.makeFault(e);
   
   //            AxisEngine engine = msgContext.getAxisEngine();
  
  
  
  1.161     +9 -3      xml-axis/java/src/org/apache/axis/client/Call.java
  
  Index: Call.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/client/Call.java,v
  retrieving revision 1.160
  retrieving revision 1.161
  diff -u -r1.160 -r1.161
  --- Call.java	20 Jul 2002 00:30:19 -0000	1.160
  +++ Call.java	24 Jul 2002 18:01:04 -0000	1.161
  @@ -146,6 +146,12 @@
       private static Log tlog =
           LogFactory.getLog("org.apache.axis.TIME");
   
  +    // The enterprise category is for stuff that an enterprise product might
  +    // want to track, but in a simple environment (like the AXIS build) would
  +    // be nothing more than a nuisance.
  +    protected static Log entLog =
  +        LogFactory.getLog(Constants.ENTERPRISE_LOG_CATEGORY);
  +
       private boolean            parmAndRetReq   = true ;
       private Service            service         = null ;
       private QName              portName        = new QName("");
  @@ -1310,7 +1316,7 @@
           }
           catch( Exception exp ) {
               //if ( exp instanceof AxisFault ) throw (AxisFault) exp ;
  -            log.info(JavaUtils.getMessage("toAxisFault00"), exp);
  +            entLog.info(JavaUtils.getMessage("toAxisFault00"), exp);
               throw new AxisFault( JavaUtils.getMessage("errorInvoking00", "\n" + exp) );
           }
       }
  @@ -1369,7 +1375,7 @@
           catch( Exception exp ) {
               if ( exp instanceof AxisFault ) throw (AxisFault) exp ;
   
  -            log.info(JavaUtils.getMessage("toAxisFault00"), exp);
  +            entLog.info(JavaUtils.getMessage("toAxisFault00"), exp);
               throw new AxisFault( JavaUtils.getMessage("errorInvoking00", "\n" + exp) );
           }
       }
  @@ -1834,7 +1840,7 @@
   
               invoke();
           } catch (Exception e) {
  -            log.info(JavaUtils.getMessage("toAxisFault00"), e);
  +            entLog.info(JavaUtils.getMessage("toAxisFault00"), e);
               throw AxisFault.makeFault(e);
           }
   
  
  
  
  1.57      +7 -1      xml-axis/java/src/org/apache/axis/handlers/JWSProcessor.java
  
  Index: JWSProcessor.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/handlers/JWSProcessor.java,v
  retrieving revision 1.56
  retrieving revision 1.57
  diff -u -r1.56 -r1.57
  --- JWSProcessor.java	10 Jul 2002 19:32:13 -0000	1.56
  +++ JWSProcessor.java	24 Jul 2002 18:01:05 -0000	1.57
  @@ -104,6 +104,12 @@
       protected static Log log =
           LogFactory.getLog(JWSProcessor.class.getName());
   
  +    // The enterprise category is for stuff that an enterprise product might
  +    // want to track, but in a simple environment (like the AXIS build) would
  +    // be nothing more than a nuisance.
  +    protected static Log entLog =
  +        LogFactory.getLog(Constants.ENTERPRISE_LOG_CATEGORY);
  +
       protected static HashMap soapServices = new HashMap();
   
       public void invoke(MessageContext msgContext) throws AxisFault
  @@ -310,7 +316,7 @@
               rpc.cleanup();  // ??
           }
           catch( Exception e ) {
  -            log.debug(JavaUtils.getMessage("toAxisFault00"), e );
  +            entLog.debug(JavaUtils.getMessage("toAxisFault00"), e );
               throw AxisFault.makeFault(e);
           }
   
  
  
  
  1.26      +8 -1      xml-axis/java/src/org/apache/axis/providers/java/EJBProvider.java
  
  Index: EJBProvider.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/providers/java/EJBProvider.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- EJBProvider.java	3 Jul 2002 17:50:34 -0000	1.25
  +++ EJBProvider.java	24 Jul 2002 18:01:05 -0000	1.26
  @@ -59,6 +59,7 @@
   
   import org.apache.axis.AxisFault;
   import org.apache.axis.AxisProperties;
  +import org.apache.axis.Constants;
   import org.apache.axis.Handler;
   import org.apache.axis.MessageContext;
   import org.apache.axis.utils.ClassUtils;
  @@ -83,6 +84,12 @@
       protected static Log log =
           LogFactory.getLog(EJBProvider.class.getName());
   
  +    // The enterprise category is for stuff that an enterprise product might
  +    // want to track, but in a simple environment (like the AXIS build) would
  +    // be nothing more than a nuisance.
  +    protected static Log entLog =
  +        LogFactory.getLog(Constants.ENTERPRISE_LOG_CATEGORY);
  +
       public static final String OPTION_BEANNAME = "beanJndiName";
       public static final String OPTION_HOMEINTERFACENAME = "homeInterfaceName";
       public static final String OPTION_REMOTEINTERFACENAME = "remoteInterfaceName";
  @@ -303,7 +310,7 @@
           }
           // Should probably catch javax.naming.NameNotFoundException here 
           catch (Exception exception) {
  -            log.info(JavaUtils.getMessage("toAxisFault00"), exception);
  +            entLog.info(JavaUtils.getMessage("toAxisFault00"), exception);
               throw AxisFault.makeFault(exception);
           }
   
  
  
  
  1.68      +9 -3      xml-axis/java/src/org/apache/axis/providers/java/JavaProvider.java
  
  Index: JavaProvider.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/providers/java/JavaProvider.java,v
  retrieving revision 1.67
  retrieving revision 1.68
  diff -u -r1.67 -r1.68
  --- JavaProvider.java	17 Jul 2002 20:27:28 -0000	1.67
  +++ JavaProvider.java	24 Jul 2002 18:01:05 -0000	1.68
  @@ -99,6 +99,12 @@
       protected static Log log =
           LogFactory.getLog(JavaProvider.class.getName());
   
  +    // The enterprise category is for stuff that an enterprise product might
  +    // want to track, but in a simple environment (like the AXIS build) would
  +    // be nothing more than a nuisance.
  +    protected static Log entLog =
  +        LogFactory.getLog(Constants.ENTERPRISE_LOG_CATEGORY);
  +
       public static final String OPTION_CLASSNAME = "className";
       public static final String OPTION_ALLOWEDMETHODS = "allowedMethods";
       public static final String OPTION_IS_STATIC = "isStatic";
  @@ -301,7 +307,7 @@
               }
           }
           catch( Exception exp ) {
  -            log.debug( JavaUtils.getMessage("toAxisFault00"), exp);
  +            entLog.debug( JavaUtils.getMessage("toAxisFault00"), exp);
               throw AxisFault.makeFault(exp);
           }
   
  @@ -433,10 +439,10 @@
   
               msgContext.setProperty("WSDL", doc);
           } catch (NoClassDefFoundError e) {
  -            log.info( JavaUtils.getMessage("toAxisFault00"), e );
  +            entLog.info( JavaUtils.getMessage("toAxisFault00"), e );
               throw new AxisFault(e.toString(), e);
           } catch (Exception e) {
  -            log.info( JavaUtils.getMessage("toAxisFault00"), e );
  +            entLog.info( JavaUtils.getMessage("toAxisFault00"), e );
               throw AxisFault.makeFault(e);
           }