You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by rd...@apache.org on 2009/09/17 14:42:37 UTC

svn commit: r816169 - /james/server/trunk/pop3server-function/src/main/java/org/apache/james/pop3server/POP3HandlerChain.java

Author: rdonkin
Date: Thu Sep 17 12:42:37 2009
New Revision: 816169

URL: http://svn.apache.org/viewvc?rev=816169&view=rev
Log:
JAMES-922 Any handlers which require other logging should implement LogEnabled https://issues.apache.org/jira/browse/JAMES-922

Modified:
    james/server/trunk/pop3server-function/src/main/java/org/apache/james/pop3server/POP3HandlerChain.java

Modified: james/server/trunk/pop3server-function/src/main/java/org/apache/james/pop3server/POP3HandlerChain.java
URL: http://svn.apache.org/viewvc/james/server/trunk/pop3server-function/src/main/java/org/apache/james/pop3server/POP3HandlerChain.java?rev=816169&r1=816168&r2=816169&view=diff
==============================================================================
--- james/server/trunk/pop3server-function/src/main/java/org/apache/james/pop3server/POP3HandlerChain.java (original)
+++ james/server/trunk/pop3server-function/src/main/java/org/apache/james/pop3server/POP3HandlerChain.java Thu Sep 17 12:42:37 2009
@@ -39,6 +39,7 @@
 import org.apache.avalon.framework.service.Serviceable;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.james.socket.LogEnabled;
 
 /**
   * The POP3HandlerChain is per service object providing access
@@ -126,6 +127,10 @@
                 //load the handler
                 try {
                     Object handler = classLoader.loadClass(className).newInstance();
+                    
+                    if (handler instanceof LogEnabled) {
+                        ((LogEnabled) handler).setLog(log);
+                    }
 
                     //servicing the handler
                     ContainerUtil.service(handler,serviceManager);



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org