|
From: <jom...@us...> - 2014-06-03 19:57:27
|
Revision: 1786
http://sourceforge.net/p/jason/svn/1786
Author: jomifred
Date: 2014-06-03 19:57:20 +0000 (Tue, 03 Jun 2014)
Log Message:
-----------
consider port in the jade main host
Modified Paths:
--------------
trunk/doc/faq/faq.tex
trunk/src/jason/infra/jade/JadeMASLauncherAnt.java
Modified: trunk/doc/faq/faq.tex
===================================================================
--- trunk/doc/faq/faq.tex 2014-06-03 18:50:24 UTC (rev 1785)
+++ trunk/doc/faq/faq.tex 2014-06-03 19:57:20 UTC (rev 1786)
@@ -16,7 +16,7 @@
\html{\begin{rawhtml}<h0><b><i>Jason</i></b> FAQ
- <br><font size="-1">(for version > 1.3.7)</font></h0>
+ <br><font size="-1">(for version > 1.4.1)</font></h0>
\end{rawhtml}}
\latex{\begin{center}{\Huge\jason FAQ}\end{center}}
Modified: trunk/src/jason/infra/jade/JadeMASLauncherAnt.java
===================================================================
--- trunk/src/jason/infra/jade/JadeMASLauncherAnt.java 2014-06-03 18:50:24 UTC (rev 1785)
+++ trunk/src/jason/infra/jade/JadeMASLauncherAnt.java 2014-06-03 19:57:20 UTC (rev 1786)
@@ -109,7 +109,18 @@
e.printStackTrace();
}
}
+ int mainHostPort = -1;
+ int pos = mainHost.indexOf(":");
+ if (pos > 0) {
+ try {
+ mainHostPort = new Integer(mainHost.substring(pos+1));
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ mainHost = mainHost.substring(0,pos);
+ }
+
// identify type of allocation (by class of info in .mas2h)
ContainerAllocation allocator = null;
String allocationClass = project.getInfrastructure().getParameter("container_allocation");
@@ -144,6 +155,8 @@
for (String container: containers) {
String sep = " ";
String args = "-container -host "+mainHost+" -container-name "+container+" ";
+ if (mainHostPort > 0)
+ args += "-port "+mainHostPort;
StringBuilder agents = new StringBuilder();
if (container.equals("Main-Container")) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|