directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r380592 - /directory/trunks/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
Date Fri, 24 Feb 2006 04:45:12 GMT
Author: trustin
Date: Thu Feb 23 20:45:06 2006
New Revision: 380592

URL: http://svn.apache.org/viewcvs?rev=380592&view=rev
Log:
Fixed a deadlock while graceful shutdown; ApacheDS was running in single thread mode.

Modified:
    directory/trunks/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java

Modified: directory/trunks/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java?rev=380592&r1=380591&r2=380592&view=diff
==============================================================================
--- directory/trunks/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
(original)
+++ directory/trunks/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
Thu Feb 23 20:45:06 2006
@@ -55,9 +55,11 @@
 import org.apache.directory.shared.ldap.message.extended.NoticeOfDisconnect;
 import org.apache.mina.common.DefaultIoFilterChainBuilder;
 import org.apache.mina.common.IoAcceptor;
+import org.apache.mina.common.IoFilter;
 import org.apache.mina.common.IoFilterChainBuilder;
 import org.apache.mina.common.IoSession;
 import org.apache.mina.common.WriteFuture;
+import org.apache.mina.filter.ThreadPoolFilter;
 import org.apache.mina.transport.socket.nio.DatagramAcceptor;
 import org.apache.mina.transport.socket.nio.SocketAcceptor;
 import org.apache.mina.transport.socket.nio.SocketAcceptorConfig;
@@ -80,6 +82,13 @@
 
     protected static final IoAcceptor tcpAcceptor = new SocketAcceptor();
     protected static final IoAcceptor udpAcceptor = new DatagramAcceptor();
+
+    static
+    {
+        IoFilter threadPool = new ThreadPoolFilter();
+        tcpAcceptor.getFilterChain().addFirst( "threadPool", threadPool );
+        udpAcceptor.getFilterChain().addFirst( "threadPool", threadPool );
+    }
 
     private static boolean ldapStarted;
     private static boolean ldapsStarted;



Mime
View raw message