activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chir...@apache.org
Subject svn commit: r464658 - in /incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport: TransportFactory.java tcp/TcpTransportServer.java
Date Mon, 16 Oct 2006 20:52:37 GMT
Author: chirino
Date: Mon Oct 16 13:52:36 2006
New Revision: 464658

URL: http://svn.apache.org/viewvc?view=rev&rev=464658
Log:
use a seperate configure method on the transport factory for when we are configureing the
server side transports.  Some transport impls are not asymetric and will need different configs.

Modified:
    incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/TransportFactory.java
    incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/tcp/TcpTransportServer.java

Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/TransportFactory.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/TransportFactory.java?view=diff&rev=464658&r1=464657&r2=464658
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/TransportFactory.java
(original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/TransportFactory.java
Mon Oct 16 13:52:36 2006
@@ -219,6 +219,24 @@
     }
 
     /**
+     * Fully configures and adds all need transport filters so that the transport
+     * can be used by the ActiveMQ message broker.  The main difference between this and
the 
+     * configure() method is that the broker does not issue requests to the client so the
+     * ResponseCorrelator is not needed.
+     * 
+     * @param transport
+     * @param wf
+     * @param options
+     * @return
+     * @throws Exception
+     */
+	public Transport serverConfigure(Transport transport, WireFormat format, HashMap options)
throws Exception {
+    	transport = compositeConfigure(transport, format, options);    	
+        transport = new MutexTransport(transport);
+        return transport;
+	}
+    
+    /**
      * Similar to configure(...) but this avoid adding in the MutexTransport and ResponseCorrelator
transport layers
      * so that the resulting transport can more efficiently be used as part of a composite
transport.
      * 

Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/tcp/TcpTransportServer.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/tcp/TcpTransportServer.java?view=diff&rev=464658&r1=464657&r2=464658
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/tcp/TcpTransportServer.java
(original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/tcp/TcpTransportServer.java
Mon Oct 16 13:52:36 2006
@@ -163,7 +163,7 @@
                         options.putAll(transportOptions);
                         WireFormat format = wireFormatFactory.createWireFormat();
                         Transport transport = createTransport(socket, format);
-                        Transport configuredTransport = transportFactory.configure(transport,
format, options);
+                        Transport configuredTransport = transportFactory.serverConfigure(transport,
format, options);
                         getAcceptListener().onAccept(configuredTransport);
                     }
                 }



Mime
View raw message