tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p...@apache.org
Subject svn commit: r332823 - in /tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11: Http11BaseProtocol.java Http11Protocol.java
Date Sat, 12 Nov 2005 19:23:04 GMT
Author: pero
Date: Sat Nov 12 11:23:00 2005
New Revision: 332823

URL: http://svn.apache.org/viewcvs?rev=332823&view=rev
Log:
Refactor connection handler for better standalone support 
without JMX.

Modified:
    tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11BaseProtocol.java
    tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11Protocol.java

Modified: tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11BaseProtocol.java
URL: http://svn.apache.org/viewcvs/tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11BaseProtocol.java?rev=332823&r1=332822&r2=332823&view=diff
==============================================================================
--- tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11BaseProtocol.java
(original)
+++ tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11BaseProtocol.java
Sat Nov 12 11:23:00 2005
@@ -104,11 +104,20 @@
     public Adapter getAdapter() {
         return adapter;
     }
-
+    
+    protected Http11ConnectionHandler createConnectionHandler() {
+        Http11ConnectionHandler cHandler = new Http11ConnectionHandler( this );
+        setSoLinger(Constants.DEFAULT_CONNECTION_LINGER);
+        setSoTimeout(Constants.DEFAULT_CONNECTION_TIMEOUT);
+        setServerSoTimeout(Constants.DEFAULT_SERVER_SOCKET_TIMEOUT);
+        setTcpNoDelay(Constants.DEFAULT_TCP_NO_DELAY);
+        return cHandler ;
+    }
 
     /** Start the protocol
      */
     public void init() throws Exception {
+        cHandler = createConnectionHandler() ;
         ep.setConnectionHandler( cHandler );
         try {
             checkSocketFactory();

Modified: tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11Protocol.java
URL: http://svn.apache.org/viewcvs/tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11Protocol.java?rev=332823&r1=332822&r2=332823&view=diff
==============================================================================
--- tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11Protocol.java (original)
+++ tomcat/connectors/trunk/http11/src/java/org/apache/coyote/http11/Http11Protocol.java Sat
Nov 12 11:23:00 2005
@@ -59,13 +59,23 @@
 public class Http11Protocol extends Http11BaseProtocol implements MBeanRegistration
 {
     public Http11Protocol() {
+        /*
         cHandler = new JmxHttp11ConnectionHandler( this );
         setSoLinger(Constants.DEFAULT_CONNECTION_LINGER);
         setSoTimeout(Constants.DEFAULT_CONNECTION_TIMEOUT);
         setServerSoTimeout(Constants.DEFAULT_SERVER_SOCKET_TIMEOUT);
         setTcpNoDelay(Constants.DEFAULT_TCP_NO_DELAY);
+        */
+    }
+    
+    protected Http11ConnectionHandler createConnectionHandler() {
+        Http11ConnectionHandler cHandler = new JmxHttp11ConnectionHandler( this );
+        setSoLinger(Constants.DEFAULT_CONNECTION_LINGER);
+        setSoTimeout(Constants.DEFAULT_CONNECTION_TIMEOUT);
+        setServerSoTimeout(Constants.DEFAULT_SERVER_SOCKET_TIMEOUT);
+        setTcpNoDelay(Constants.DEFAULT_TCP_NO_DELAY);
+        return cHandler ;
     }
-
 
     ObjectName tpOname;
     ObjectName rgOname;



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


Mime
View raw message