[jboss-remoting-commits] JBoss Remoting SVN: r5256 - remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket.

jboss-remoting-commits at lists.jboss.org jboss-remoting-commits at lists.jboss.org
Sat May 16 20:39:21 EDT 2009


Author: ron.sigal at jboss.com
Date: 2009-05-16 20:39:21 -0400 (Sat, 16 May 2009)
New Revision: 5256

Modified:
   remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/ServerThread.java
Log:
JBREM-1102: Uses passConfigMapToMarshalFactory variable.

Modified: remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/ServerThread.java
===================================================================
--- remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/ServerThread.java	2009-05-17 00:39:00 UTC (rev 5255)
+++ remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/ServerThread.java	2009-05-17 00:39:21 UTC (rev 5256)
@@ -999,9 +999,24 @@
          configMap = invoker.getConfiguration();
       }
       
+      boolean passConfigMapToMarshalFactory = false;
+      if (configMap != null)
+      {
+         Object o = configMap.get(Remoting.PASS_CONFIG_MAP_TO_MARSHAL_FACTORY);
+         if (o instanceof String)
+         {
+            passConfigMapToMarshalFactory = Boolean.valueOf((String) o).booleanValue();
+         }
+         else if (o != null)
+         {
+            log.warn("Value of " + Remoting.PASS_CONFIG_MAP_TO_MARSHAL_FACTORY + " should be of type String: " + o);
+         }
+      }
+      
+      Map map = passConfigMapToMarshalFactory ? configMap : null;
       if (unmarshaller == null)
       {
-         unmarshaller = MarshalFactory.getUnMarshaller(locator, classLoader, configMap);
+         unmarshaller = MarshalFactory.getUnMarshaller(locator, classLoader, map);
       }
       if (unmarshaller == null)
       {
@@ -1010,7 +1025,7 @@
 
       if (marshaller == null)
       {
-         marshaller = MarshalFactory.getMarshaller(locator, classLoader, configMap);
+         marshaller = MarshalFactory.getMarshaller(locator, classLoader, map);
       }
       if (marshaller == null)
       {




More information about the jboss-remoting-commits mailing list