You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beehive.apache.org by ek...@apache.org on 2005/06/10 00:13:27 UTC

svn commit: r189836 - in /incubator/beehive/trunk: system-controls/src/webservice/org/apache/beehive/controls/system/webservice/generator/ wsm/ wsm/drt/ wsm/src/runtime/org/apache/beehive/wsm/axis/ wsm/src/runtime/org/apache/beehive/wsm/axis/databinding/ wsm/src/runtime/org/apache/beehive/wsm/axis/handlers/ wsm/src/runtime/org/apache/beehive/wsm/axis/registration/ wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/ wsm/src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/ wsm/src/runtime/org/apache/beehive/wsm/registration/

Author: ekoneil
Date: Thu Jun  9 15:13:24 2005
New Revision: 189836

URL: http://svn.apache.org/viewcvs?rev=189836&view=rev
Log:
Switch WSM logging onto commons-logging.  The default log4j logger is still wired up (as there's no other configuration here).

Would be worth looking at doing a commons-discovery solution for finding an implementation of commons-logging's Log interface.  That way, it'd be really easy to add non-Log4J implementations of logging here.  Hmm...  :)

Also make the WSDLFilter final in ExtensionMaker.

BB: self
DRT: Beehive pass / build.dist pass


Modified:
    incubator/beehive/trunk/system-controls/src/webservice/org/apache/beehive/controls/system/webservice/generator/ExtensionMaker.java
    incubator/beehive/trunk/wsm/build.xml
    incubator/beehive/trunk/wsm/drt/build.xml
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/AxisHook.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/databinding/AxisTypeLookup.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/handlers/AnnotatedWebServiceDeploymentHandler.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/registration/AxisTypeRegistrar.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/AxisSecurityModel.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/BeehiveMemorySecurityModel.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/ServletSecurityModel.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/XmlBeanTypeLookup.java
    incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java

Modified: incubator/beehive/trunk/system-controls/src/webservice/org/apache/beehive/controls/system/webservice/generator/ExtensionMaker.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/system-controls/src/webservice/org/apache/beehive/controls/system/webservice/generator/ExtensionMaker.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/system-controls/src/webservice/org/apache/beehive/controls/system/webservice/generator/ExtensionMaker.java (original)
+++ incubator/beehive/trunk/system-controls/src/webservice/org/apache/beehive/controls/system/webservice/generator/ExtensionMaker.java Thu Jun  9 15:13:24 2005
@@ -48,7 +48,7 @@
  */
 public class ExtensionMaker {
 
-    private static FileFilter FILE_FILTER_WSDL = new WSDLFilter();
+    private static final FileFilter FILE_FILTER_WSDL = new WSDLFilter();
 
     private static final String[] standardImports = {
             "org.apache.beehive.controls.api.bean.ControlExtension",

Modified: incubator/beehive/trunk/wsm/build.xml
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/build.xml?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/build.xml (original)
+++ incubator/beehive/trunk/wsm/build.xml Thu Jun  9 15:13:24 2005
@@ -41,8 +41,8 @@
 
     <path id="runtime.classpath">
         <path refid="velocity.dependency.path"/>
+        <path refid="commons-logging.dependency.path"/>
         <path refid="xbean.dependency.path"/>
-        <path refid="log4j.dependency.path"/>
         <path refid="junit.dependency.path"/>
         <path refid="tools.dependency.path"/>
         <path refid="ant-jar.dependency.path"/>

Modified: incubator/beehive/trunk/wsm/drt/build.xml
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/build.xml?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/drt/build.xml (original)
+++ incubator/beehive/trunk/wsm/drt/build.xml Thu Jun  9 15:13:24 2005
@@ -34,7 +34,6 @@
     <path id="drt.classpath">
         <path refid="velocity.dependency.path"/>
         <path refid="xbean.dependency.path"/>
-        <path refid="log4j.dependency.path"/>
         <path refid="junit.dependency.path"/>
         <path refid="tools.dependency.path"/>
         <path refid="commons-codec.dependency.path"/>

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/AxisHook.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/AxisHook.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/AxisHook.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/AxisHook.java Thu Jun  9 15:13:24 2005
@@ -50,8 +50,6 @@
 import org.apache.axis.encoding.ser.BeanSerializerFactory;
 import org.apache.axis.utils.BeanPropertyDescriptor;
 import org.apache.axis.utils.BeanUtils;
-import org.apache.axis.wsdl.fromJava.Namespaces;
-import org.apache.axis.wsdl.fromJava.Types;
 import org.apache.beehive.wsm.axis.databinding.SystemTypeLookupService;
 import org.apache.beehive.wsm.axis.registration.AxisTypeMappingMetaData;
 import org.apache.beehive.wsm.axis.util.encoding.XmlBeanDeserializerFactory;
@@ -63,7 +61,8 @@
 import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
 import org.apache.beehive.wsm.registration.TypeRegistrar;
 import org.apache.beehive.wsm.util.InvalidTypeMappingException;
-import org.apache.log4j.Logger;
+import org.apache.commons.logging.LogFactory;
+import org.apache.commons.logging.Log;
 import org.apache.xmlbeans.XmlBeans;
 import org.apache.xmlbeans.XmlObject;
 
@@ -73,7 +72,8 @@
  * @author Jonathan Colwell
  */
 public class AxisHook {
-    static Logger logger = Logger.getLogger(AxisHook.class);
+
+    private static Log LOGGER = LogFactory.getLog(AxisHook.class);
 
     public static ServiceDesc createServiceDesc(BeehiveWsTypeMetadata wsm, ClassLoader cl)
         throws ClassNotFoundException, InvalidTypeMappingException {
@@ -203,7 +203,7 @@
                 for(Class thrown : javaMethod.getExceptionTypes()) {
                     FaultDesc fd = od.getFaultByClass(thrown);
                     if(null == fd) {
-                        logger.info("Exception: "
+                        LOGGER.info("Exception: "
                             + thrown.getCanonicalName()
                             + " is not picked up by the Axis, only non Remote and Application Specific exceptions are registed in Axis.  This is not a fatal error.");
                         continue;
@@ -555,8 +555,7 @@
 
         }
         catch(RuntimeException e) {
-            logger.error("Error in type registeration", e);
-            e.printStackTrace();
+            LOGGER.error("Error in type registeration", e);
             throw e;
         }
     }

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/databinding/AxisTypeLookup.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/databinding/AxisTypeLookup.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/databinding/AxisTypeLookup.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/databinding/AxisTypeLookup.java Thu Jun  9 15:13:24 2005
@@ -28,12 +28,10 @@
 import org.apache.axis.wsdl.toJava.Utils;
 import org.apache.beehive.wsm.axis.registration.AxisTypeMappingMetaData;
 import org.apache.beehive.wsm.databinding.BindingLookupService;
-import org.apache.log4j.Logger;
 
 public class AxisTypeLookup
     implements BindingLookupService {
 
-    private static Logger logger = Logger.getLogger(AxisTypeLookup.class);
     private static final char[] pkgSeparators = {'.', ':'};
 
     public AxisTypeLookup() {

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/handlers/AnnotatedWebServiceDeploymentHandler.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/handlers/AnnotatedWebServiceDeploymentHandler.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/handlers/AnnotatedWebServiceDeploymentHandler.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/handlers/AnnotatedWebServiceDeploymentHandler.java Thu Jun  9 15:13:24 2005
@@ -42,7 +42,8 @@
 import org.apache.beehive.wsm.model.BeehiveWsSOAPMessageHandlerInfo;
 import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
 import org.apache.beehive.wsm.model.jsr181.Jsr181ObjectModelStore;
-import org.apache.log4j.Logger;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 /**
  * ****************************************************************************
@@ -60,7 +61,7 @@
     extends BasicHandler {
 
     private static final String JWS_EXTENSION = ".jws";
-    private static Logger logger = Logger.getLogger(AnnotatedWebServiceDeploymentHandler.class);
+    private static Log LOGGER = LogFactory.getLog(AnnotatedWebServiceDeploymentHandler.class);
 
     private Map<String, SOAPService> soapServices = new HashMap<String, SOAPService>();
 
@@ -237,13 +238,11 @@
             className = relativePath.substring(1, relativePath.length()).replaceAll("/", ".");
 
         // load class
-        if(logger.isDebugEnabled())
-            logger.debug("trying to load web service class: " + className);
+        LOGGER.debug("trying to load web service class: " + className);
 
         Class clazz = Jsr181ObjectModelStore.loadWebServiceClass(className);
         if(null == clazz)
-            if(logger.isDebugEnabled())
-                logger.debug("failed to load web service class: " + className);
+            LOGGER.debug("failed to load web service class: " + className);
 
         return clazz;
     }

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/registration/AxisTypeRegistrar.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/registration/AxisTypeRegistrar.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/registration/AxisTypeRegistrar.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/registration/AxisTypeRegistrar.java Thu Jun  9 15:13:24 2005
@@ -42,11 +42,13 @@
 import org.apache.beehive.wsm.axis.util.encoding.XmlBeanSerializerFactory;
 import org.apache.beehive.wsm.databinding.BindingLookupService;
 import org.apache.beehive.wsm.registration.TypeRegistrar;
-import org.apache.log4j.Logger;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 public class AxisTypeRegistrar
     extends TypeRegistrar {
-    static Logger logger = Logger.getLogger(AxisTypeRegistrar.class);
+
+    private static Log LOGGER = LogFactory.getLog(AxisTypeRegistrar.class);
 
     public AxisTypeRegistrar(TypeMapping tm, BindingLookupService lookupService) {
         super(tm, lookupService);
@@ -66,7 +68,7 @@
      */
     protected void registerClassAsWithDefaultSearialization(Class cls, QName q, SOAPBinding.Style style, SOAPBinding.Use use) {
         try {
-            logger.debug("Assigned Default Serialization to  class: " + cls.getCanonicalName() + " qname:" + q);
+            LOGGER.debug("Assigned Default Serialization to  class: " + cls.getCanonicalName() + " qname:" + q);
             TypeDesc td = TypeDesc.getTypeDescForClass(cls);
             // a class can provide its own descriptors
             TypeDesc superTd = null;
@@ -138,7 +140,7 @@
             }
         }
         catch(RuntimeException e) {
-            logger.error("Error in registering class: " + cls.getCanonicalName() + " qname:" + q);
+            LOGGER.error("Error in registering class: " + cls.getCanonicalName() + " qname:" + q);
             e.printStackTrace();
             throw e;
         }
@@ -149,7 +151,7 @@
      * @param q
      */
     protected void registerClassAsXMLBeans(Class cls, QName q) {
-        logger.debug("Assigned XMLBeans Serialization to  class: " + cls.getCanonicalName() + " qname:" + q);
+        LOGGER.debug("Assigned XMLBeans Serialization to  class: " + cls.getCanonicalName() + " qname:" + q);
         mTypeMapping.register(cls, q, new XmlBeanSerializerFactory(cls, q), new XmlBeanDeserializerFactory(cls, q));
     }
 
@@ -166,7 +168,7 @@
         throws ClassNotFoundException, NoSuchMethodException,
         InstantiationException, IllegalAccessException,
         InvocationTargetException {
-        logger.debug("Assigned DataHandler to  class: " + cls.getCanonicalName() + " qname:" + q);
+        LOGGER.debug("Assigned DataHandler to  class: " + cls.getCanonicalName() + " qname:" + q);
         /*
          * NOTE jcolwell@bea.com 2004-Oct-08 -- doing reflection here in case
          * AXIS was built without attachment support.
@@ -188,7 +190,7 @@
      * @param q
      */
     protected void registerClassAsSoapEncodedArray(Class cls, QName q) {
-        logger.debug("Assigned Array Serialization to  class: " + cls.getCanonicalName()
+        LOGGER.debug("Assigned Array Serialization to  class: " + cls.getCanonicalName()
             + " qname:" + q + " Array element qname: " + lookupService.class2qname(cls.getComponentType()));
 
         mTypeMapping.register(cls, q, new ArraySerializerFactory(lookupService.class2qname(cls.getComponentType())),

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/AxisSecurityModel.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/AxisSecurityModel.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/AxisSecurityModel.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/AxisSecurityModel.java Thu Jun  9 15:13:24 2005
@@ -28,11 +28,13 @@
 import org.apache.axis.security.servlet.ServletSecurityProvider;
 import org.apache.axis.security.simple.SimpleSecurityProvider;
 import org.apache.beehive.wsm.axis.security.SecurityModel;
-import org.apache.log4j.Logger;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 public class AxisSecurityModel
     implements SecurityModel {
-    protected static Logger logger = Logger.getLogger(AxisSecurityModel.class);
+
+    private static Log LOGGER = LogFactory.getLog(AxisSecurityModel.class);
 
     public void init(MessageContext msgContext) {
     }
@@ -42,8 +44,8 @@
      */
     public boolean isUserInRole(MessageContext msgContext, Collection<String> rolesAllowed) {
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("Enter: AxisSecurityModel::isUserInRole");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Enter: AxisSecurityModel::isUserInRole");
         }
 
         SecurityProvider provider = (SecurityProvider)msgContext.getProperty(MessageContext.SECURITY_PROVIDER);
@@ -55,26 +57,26 @@
 
         if(provider != null) {
             String userID = msgContext.getUsername();
-            if(logger.isDebugEnabled()) {
-                logger.debug("user : " + userID);
+            if(LOGGER.isDebugEnabled()) {
+                LOGGER.debug("user : " + userID);
             }
 
             // in order to authenticate, the user must exist
             if(userID == null || userID.equals("")) {
-                logger.debug("userID is null");
+                LOGGER.debug("userID is null");
                 return false;
             }
 
             String passwd = msgContext.getPassword();
-            if(logger.isDebugEnabled()) {
-                logger.debug("password : " + passwd);
+            if(LOGGER.isDebugEnabled()) {
+                LOGGER.debug("password : " + passwd);
             }
 
             AuthenticatedUser authUser = provider.authenticate(msgContext);
 
             // if a password is defined, then it must match
             if(authUser == null) {
-                logger.debug("authuser is null");
+                LOGGER.debug("authuser is null");
                 return false;
             }
 
@@ -83,8 +85,8 @@
                 if(provider.userMatches(authUser, role)) {
                     // BINGO !!
 
-                    if(logger.isDebugEnabled()) {
-                        logger.debug("auth : " + userID + " is in role [" + role + "]");
+                    if(LOGGER.isDebugEnabled()) {
+                        LOGGER.debug("auth : " + userID + " is in role [" + role + "]");
                     }
                     msgContext.setProperty(SecurityModel.BEEHIVE_AUTHUSER, authUser);
                     return true;
@@ -92,8 +94,8 @@
             }
         }
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("Exit: AxisSecurityModel::isUserInRole");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Exit: AxisSecurityModel::isUserInRole");
         }
 
         return false;

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/BeehiveMemorySecurityModel.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/BeehiveMemorySecurityModel.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/BeehiveMemorySecurityModel.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/BeehiveMemorySecurityModel.java Thu Jun  9 15:13:24 2005
@@ -29,12 +29,13 @@
 import org.apache.beehive.wsm.axis.security.UserList;
 import org.apache.beehive.wsm.axis.security.xmlbeans.BeehiveRoleDocument;
 import org.apache.beehive.wsm.axis.security.xmlbeans.BeehiveRoleDocument.BeehiveRole;
-import org.apache.log4j.Logger;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 public class BeehiveMemorySecurityModel
     implements SecurityModel {
 
-    protected static Logger logger = Logger.getLogger(BeehiveMemorySecurityModel.class);
+    private static Log LOGGER = LogFactory.getLog(BeehiveMemorySecurityModel.class);
 
     private static final String BEEHIVE_ROLE_FILE = "beehive-role.xml";
 
@@ -43,8 +44,8 @@
 
     public void init(MessageContext msgContext) {
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("Enter: BeehiveMemorySecurityModel::init");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Enter: BeehiveMemorySecurityModel::init");
         }
 
         if(userList != null) {
@@ -63,8 +64,8 @@
                     configPath += File.separator;
                 }
 
-                if(logger.isDebugEnabled()) {
-                    logger.debug("BEEHIVE_ROLE_FILE : " + configPath + BEEHIVE_ROLE_FILE);
+                if(LOGGER.isDebugEnabled()) {
+                    LOGGER.debug("BEEHIVE_ROLE_FILE : " + configPath + BEEHIVE_ROLE_FILE);
                 }
 
                 BeehiveRoleDocument brd = null;
@@ -72,7 +73,7 @@
                     brd = BeehiveRoleDocument.Factory.parse(new File(configPath + BEEHIVE_ROLE_FILE));
                 }
                 catch(Exception e) {
-                    logger.error("BeehiveRoleDocument couldn't parse the file (" + configPath + BEEHIVE_ROLE_FILE + ") : " + e.getMessage(), e);
+                    LOGGER.error("BeehiveRoleDocument couldn't parse the file (" + configPath + BEEHIVE_ROLE_FILE + ") : " + e.getMessage(), e);
                     return;
                 }
 
@@ -80,8 +81,8 @@
             }
 
         } // synchronized
-        if(logger.isDebugEnabled()) {
-            logger.debug("Exit : BeehiveMemorySecurityModel::init");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Exit : BeehiveMemorySecurityModel::init");
         }
     }
 
@@ -111,8 +112,8 @@
                     if(groupName.equals(group.getName())) {
                         Role memoryRole = userList.getRole(role.getName());
                         if(memoryRole != null) {
-                            if(logger.isDebugEnabled()) {
-                                logger.debug("GROUP : " + memoryGroup.getName() + " in ROLE : " + memoryRole.getName());
+                            if(LOGGER.isDebugEnabled()) {
+                                LOGGER.debug("GROUP : " + memoryGroup.getName() + " in ROLE : " + memoryRole.getName());
                             }
                             memoryGroup.addRole(memoryRole);
                         }
@@ -134,8 +135,8 @@
                     if(userName.equals(user.getName())) {
                         Group memoryGroup = userList.getGroup(group.getName());
                         if(memoryGroup != null) {
-                            if(logger.isDebugEnabled()) {
-                                logger.debug("USER : " + memoryUser.getName() + " in GROUP : " + memoryGroup.getName());
+                            if(LOGGER.isDebugEnabled()) {
+                                LOGGER.debug("USER : " + memoryUser.getName() + " in GROUP : " + memoryGroup.getName());
                             }
 
                             // User and Group hold references to each other
@@ -157,8 +158,8 @@
                     if(userName.equals(user.getName())) {
                         Role memoryRole = userList.getRole(role.getName());
                         if(memoryRole != null) {
-                            if(logger.isDebugEnabled()) {
-                                logger.debug("USER : " + memoryUser.getName() + " in ROLE : " + memoryRole.getName());
+                            if(LOGGER.isDebugEnabled()) {
+                                LOGGER.debug("USER : " + memoryUser.getName() + " in ROLE : " + memoryRole.getName());
                             }
                             memoryUser.addRole(memoryRole);
                         }
@@ -173,53 +174,53 @@
 
     public boolean isUserInRole(MessageContext msgContext, Collection<String> rolesAllowed) {
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("Enter: BeehiveMemorySecurityModel::isUserInRole");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Enter: BeehiveMemorySecurityModel::isUserInRole");
         }
 
         String username = msgContext.getUsername();
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("username from client : " + username);
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("username from client : " + username);
         }
 
         if(username == null) {
             return false; // user didn't specify username.
         }
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("username from client : " + username);
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("username from client : " + username);
         }
 
         User user = userList.getUser(username);
         if(user == null) {
-            if(logger.isDebugEnabled()) {
-                logger.debug("user returned from userList is null");
+            if(LOGGER.isDebugEnabled()) {
+                LOGGER.debug("user returned from userList is null");
             }
             return false; // user doesn't exist.
         }
 
         if(! user.authenticate(msgContext.getPassword())) {
-            if(logger.isDebugEnabled()) {
-                logger.debug("authenticate failed");
+            if(LOGGER.isDebugEnabled()) {
+                LOGGER.debug("authenticate failed");
             }
             return false; // password doesn't match.
         }
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("authenticate passed (" + username + ")");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("authenticate passed (" + username + ")");
         }
 
         for(Role role : user.getRoles()) {
 
-            if(logger.isDebugEnabled()) {
-                logger.debug("user [" + user.getName() + "] role [" + role.getName() + "]");
+            if(LOGGER.isDebugEnabled()) {
+                LOGGER.debug("user [" + user.getName() + "] role [" + role.getName() + "]");
             }
 
             for(String roleAllowed : rolesAllowed) {
                 if(role.getName().equals(roleAllowed)) {
-                    if(logger.isDebugEnabled()) {
-                        logger.debug("auth : " + user.getName() + " is in role [" + roleAllowed + "]");
+                    if(LOGGER.isDebugEnabled()) {
+                        LOGGER.debug("auth : " + user.getName() + " is in role [" + roleAllowed + "]");
                     }
                     msgContext.setProperty(SecurityModel.BEEHIVE_AUTHUSER, user);
                     return true;
@@ -227,8 +228,8 @@
             }
         }
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("Exit: BeehiveMemorySecurityModel::isUserInRole");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Exit: BeehiveMemorySecurityModel::isUserInRole");
         }
 
         return false;

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/ServletSecurityModel.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/ServletSecurityModel.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/ServletSecurityModel.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/axis/security/model/ServletSecurityModel.java Thu Jun  9 15:13:24 2005
@@ -27,11 +27,13 @@
 import org.apache.axis.security.SecurityProvider;
 import org.apache.axis.security.simple.SimpleSecurityProvider;
 import org.apache.beehive.wsm.axis.security.SecurityModel;
-import org.apache.log4j.Logger;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 public class ServletSecurityModel
     implements SecurityModel {
-    protected static Logger logger = Logger.getLogger(ServletSecurityModel.class);
+
+    private static Log LOGGER = LogFactory.getLog(ServletSecurityModel.class);
 
     public void init(MessageContext msgContext) {
         // do nothing
@@ -42,8 +44,8 @@
      */
     public boolean isUserInRole(MessageContext msgContext, Collection<String> rolesAllowed) {
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("Enter: ServletSecurityModel::isUserInRole");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Enter: ServletSecurityModel::isUserInRole");
         }
 
         SecurityProvider provider = (SecurityProvider)msgContext.getProperty(MessageContext.SECURITY_PROVIDER);
@@ -54,26 +56,26 @@
 
         if(provider != null) {
             String userID = msgContext.getUsername();
-            if(logger.isDebugEnabled()) {
-                logger.debug("user : " + userID);
+            if(LOGGER.isDebugEnabled()) {
+                LOGGER.debug("user : " + userID);
             }
 
             // in order to authenticate, the user must exist
             if(userID == null || userID.equals("")) {
-                logger.debug("userID is null");
+                LOGGER.debug("userID is null");
                 return false;
             }
 
             String passwd = msgContext.getPassword();
-            if(logger.isDebugEnabled()) {
-                logger.debug("password : " + passwd);
+            if(LOGGER.isDebugEnabled()) {
+                LOGGER.debug("password : " + passwd);
             }
 
             AuthenticatedUser authUser = provider.authenticate(msgContext);
 
             // if a password is defined, then it must match
             if(authUser == null) {
-                logger.debug("authuser is null");
+                LOGGER.debug("authuser is null");
                 return false;
             }
 
@@ -81,8 +83,8 @@
                 if(provider.userMatches(authUser, role)) {
                     // BINGO !!
 
-                    if(logger.isDebugEnabled()) {
-                        logger.debug("auth : " + userID + " is in role [" + role + "]");
+                    if(LOGGER.isDebugEnabled()) {
+                        LOGGER.debug("auth : " + userID + " is in role [" + role + "]");
                     }
                     msgContext.setProperty(SecurityModel.BEEHIVE_AUTHUSER, authUser);
                     return true;
@@ -90,8 +92,8 @@
             }
         }
 
-        if(logger.isDebugEnabled()) {
-            logger.debug("Exit: ServletSecurityModel::isUserInRole");
+        if(LOGGER.isDebugEnabled()) {
+            LOGGER.debug("Exit: ServletSecurityModel::isUserInRole");
         }
 
         return false;

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/XmlBeanTypeLookup.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/XmlBeanTypeLookup.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/XmlBeanTypeLookup.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/XmlBeanTypeLookup.java Thu Jun  9 15:13:24 2005
@@ -23,18 +23,19 @@
 import javax.xml.namespace.QName;
 
 import org.apache.beehive.wsm.databinding.BindingLookupService;
-import org.apache.log4j.Logger;
 import org.apache.xmlbeans.SchemaField;
 import org.apache.xmlbeans.SchemaType;
 import org.apache.xmlbeans.SchemaTypeLoader;
 import org.apache.xmlbeans.XmlBeans;
 import org.apache.xmlbeans.XmlObject;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 
 public class XmlBeanTypeLookup
     implements BindingLookupService {
 
-    private static Logger LOGGER = Logger.getLogger(XmlBeanTypeLookup.class);
+    private static Log LOGGER = LogFactory.getLog(XmlBeanTypeLookup.class);
     private static XmlBeanTypeLookup THE_LOOKUP = new XmlBeanTypeLookup();
 
     public QName class2qname(Class cls) {

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java?rev=189836&r1=189835&r2=189836&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java Thu Jun  9 15:13:24 2005
@@ -34,11 +34,12 @@
 
 import org.apache.beehive.wsm.databinding.BindingLookupService;
 import org.apache.beehive.wsm.databinding.GenericHolder;
-import org.apache.log4j.Logger;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 public abstract class TypeRegistrar {
 
-    private static Logger logger = Logger.getLogger(TypeRegistrar.class);
+    private static Log LOGGER = LogFactory.getLog(TypeRegistrar.class);
 
     /* todo: need to figure out how to protect these since they're used by subclasses */
     protected TypeMapping mTypeMapping;
@@ -127,7 +128,7 @@
 
     public QName registerType(Class cls, QName q, SOAPBinding.Style style, SOAPBinding.Use use) {
         try {
-            logger.debug("Register class: " + cls.getCanonicalName() + " qName: " + q);
+            LOGGER.debug("Register class: " + cls.getCanonicalName() + " qName: " + q);
 
             if(Void.TYPE.equals(cls))
                 return null;
@@ -200,11 +201,11 @@
                         + " consider using a custom type mapping");
                 }
             }
-            logger.info("Registered class: " + cls.getCanonicalName() + " qName: " + q);
+            LOGGER.info("Registered class: " + cls.getCanonicalName() + " qName: " + q);
             return q;
         }
         catch(RuntimeException e) {
-            logger.error("Failed to register class: " + cls.getCanonicalName()
+            LOGGER.error("Failed to register class: " + cls.getCanonicalName()
                 + " type: " + q.getNamespaceURI() + ":" + q.getLocalPart());
 
             e.printStackTrace();