axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From az...@apache.org
Subject svn commit: r594817 - in /webservices/axis2/trunk/java/modules: clustering/src/org/apache/axis2/clustering/tribes/TribesClusterManager.java kernel/src/org/apache/axis2/clustering/ClusteringConstants.java
Date Wed, 14 Nov 2007 10:02:37 GMT
Author: azeez
Date: Wed Nov 14 02:02:35 2007
New Revision: 594817

URL: http://svn.apache.org/viewvc?rev=594817&view=rev
Log:
Added the ability to be able to extenally specify the local IP address using a System property.
If this is not specified, Tribes will pick up this address from the /etc/hosts file


Modified:
    webservices/axis2/trunk/java/modules/clustering/src/org/apache/axis2/clustering/tribes/TribesClusterManager.java
    webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/ClusteringConstants.java

Modified: webservices/axis2/trunk/java/modules/clustering/src/org/apache/axis2/clustering/tribes/TribesClusterManager.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/clustering/src/org/apache/axis2/clustering/tribes/TribesClusterManager.java?rev=594817&r1=594816&r2=594817&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/clustering/src/org/apache/axis2/clustering/tribes/TribesClusterManager.java
(original)
+++ webservices/axis2/trunk/java/modules/clustering/src/org/apache/axis2/clustering/tribes/TribesClusterManager.java
Wed Nov 14 02:02:35 2007
@@ -46,6 +46,7 @@
 import org.apache.catalina.tribes.Member;
 import org.apache.catalina.tribes.group.GroupChannel;
 import org.apache.catalina.tribes.group.interceptors.DomainFilterInterceptor;
+import org.apache.catalina.tribes.transport.ReceiverBase;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 
@@ -132,6 +133,12 @@
 
         controlCmdProcessor.setChannelSender(sender);
         channel = new GroupChannel();
+
+        String localIP = System.getProperty("local.ip.address"); //TODO: Use ClusteringConstants.LOCAL_IP_ADDRESS
+        if (localIP != null) {
+            ReceiverBase receiver = (ReceiverBase) channel.getChannelReceiver();
+            receiver.setAddress(localIP);
+        }
 
         // Set the domain for this Node
         Parameter domainParam = getParameter(ClusteringConstants.DOMAIN);

Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/ClusteringConstants.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/ClusteringConstants.java?rev=594817&r1=594816&r2=594817&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/ClusteringConstants.java
(original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/ClusteringConstants.java
Wed Nov 14 02:02:35 2007
@@ -32,4 +32,5 @@
     public static final String CLUSTER_INITIALIZED = "local_cluster.initialized";
     public static final String TIME_TO_SEND = "local_cluster.time.to.send";
     public static final String BLOCK_ALL_REQUESTS = "local_wso2wsas.block.requests";
+    public static final String LOCAL_IP_ADDRESS = "local.ip.address";
 }



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Mime
View raw message