Enhanced a number of the test scripts and replaced hazelcast.xml with a mildly augmented version of the 3.3 one.
diff --git a/tools/dev/bash_profile b/tools/dev/bash_profile
index 328f5f4..d5d11bd 100644
--- a/tools/dev/bash_profile
+++ b/tools/dev/bash_profile
@@ -41,7 +41,7 @@
# Short-hand to launch API docs and sample topology viewer GUI
alias docs='open $ONOS_ROOT/target/site/apidocs/index.html'
-alias gui='open http://localhost:8181/onos/tvue'
+alias gui='onos-gui'
# Test related conveniences
diff --git a/tools/package/bin/onos-ctl b/tools/package/bin/onos-service
similarity index 100%
rename from tools/package/bin/onos-ctl
rename to tools/package/bin/onos-service
diff --git a/tools/package/debian/onos.conf b/tools/package/debian/onos.conf
index d398bda..0d4cd6e 100644
--- a/tools/package/debian/onos.conf
+++ b/tools/package/debian/onos.conf
@@ -16,6 +16,6 @@
script
[ -f /opt/onos/options ] && . /opt/onos/options
start-stop-daemon --signal INT --start --chuid sdn \
- --exec /opt/onos/bin/onos-ctl -- $ONOS_OPTS \
+ --exec /opt/onos/bin/onos-service -- $ONOS_OPTS \
>/opt/onos/var/stdout.log 2>/opt/onos/var/stderr.log
end script
diff --git a/tools/package/etc/hazelcast.xml b/tools/package/etc/hazelcast.xml
index abd6223..b950768 100644
--- a/tools/package/etc/hazelcast.xml
+++ b/tools/package/etc/hazelcast.xml
@@ -1,5 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
-<hazelcast xsi:schemaLocation="http://www.hazelcast.com/schema/config hazelcast-config-3.2.xsd"
+<!--
+ ~ Copyright (c) 2008-2013, Hazelcast, Inc. All Rights Reserved.
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+
+<!--
+ The default Hazelcast configuration. This is used when:
+
+ - no hazelcast.xml if present
+
+-->
+<hazelcast xsi:schemaLocation="http://www.hazelcast.com/schema/config hazelcast-config-3.3.xsd"
xmlns="http://www.hazelcast.com/schema/config"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<group>
@@ -11,8 +33,8 @@
<port auto-increment="true" port-count="100">5701</port>
<outbound-ports>
<!--
- Allowed port range when connecting to other nodes.
- 0 or * means use system provided port.
+ Allowed port range when connecting to other nodes.
+ 0 or * means use system provided port.
-->
<ports>0</ports>
</outbound-ports>
@@ -24,18 +46,6 @@
<tcp-ip enabled="false">
<interface>127.0.0.1</interface>
</tcp-ip>
- <aws enabled="false">
- <access-key>my-access-key</access-key>
- <secret-key>my-secret-key</secret-key>
- <!--optional, default is us-east-1 -->
- <region>us-west-1</region>
- <!--optional, default is ec2.amazonaws.com. If set, region shouldn't be set as it will override this property -->
- <host-header>ec2.amazonaws.com</host-header>
- <!-- optional, only instances belonging to this group will be discovered, default will try all running instances -->
- <security-group-name>hazelcast-sg</security-group-name>
- <tag-key>type</tag-key>
- <tag-value>hz-nodes</tag-value>
- </aws>
</join>
<interfaces enabled="true">
<interface>192.168.56.*</interface>
@@ -61,9 +71,9 @@
</symmetric-encryption>
</network>
<partition-group enabled="false"/>
- <executor-service>
+ <executor-service name="default">
<pool-size>16</pool-size>
- <!-- Queue capacity. 0 means Integer.MAX_VALUE -->
+ <!--Queue capacity. 0 means Integer.MAX_VALUE.-->
<queue-capacity>0</queue-capacity>
</executor-service>
<queue name="default">
@@ -81,22 +91,24 @@
fail-safety. 0 means no backup.
-->
<backup-count>1</backup-count>
+
<!--
Number of async backups. 0 means no backup.
-->
<async-backup-count>0</async-backup-count>
+
<empty-queue-ttl>-1</empty-queue-ttl>
</queue>
-
<map name="default">
<!--
- Data type that will be used for storing recordMap.
- Possible values:
- BINARY (default): keys and values will be stored as binary data
- OBJECT : values will be stored in their object forms
- OFFHEAP : values will be stored in non-heap region of JVM
+ Data type that will be used for storing recordMap.
+ Possible values:
+ BINARY (default): keys and values will be stored as binary data
+ OBJECT : values will be stored in their object forms
+ OFFHEAP : values will be stored in non-heap region of JVM
-->
<in-memory-format>BINARY</in-memory-format>
+
<!--
Number of backups. If 1 is set as the backup-count for example,
then all entries of the map will be copied to another JVM for
@@ -144,6 +156,12 @@
-->
<eviction-percentage>25</eviction-percentage>
<!--
+ Minimum time in milliseconds which should pass before checking
+ if a partition of this map is evictable or not.
+ Default value is 100 millis.
+ -->
+ <min-eviction-check-millis>100</min-eviction-check-millis>
+ <!--
While recovering from split-brain (network partitioning),
map entries in the small cluster will merge into the bigger cluster
based on the policy set here. When an entry merge into the
@@ -159,6 +177,7 @@
com.hazelcast.map.merge.LatestUpdateMapMergePolicy ; entry with the latest update wins.
-->
<merge-policy>com.hazelcast.map.merge.PassThroughMergePolicy</merge-policy>
+
</map>
<multimap name="default">
@@ -199,5 +218,6 @@
<portable-version>0</portable-version>
</serialization>
- <services enable-defaults="true" />
+ <services enable-defaults="true"/>
+
</hazelcast>
diff --git a/tools/test/bin/onos b/tools/test/bin/onos
index f8e62dc..74bf1cf 100755
--- a/tools/test/bin/onos
+++ b/tools/test/bin/onos
@@ -1,6 +1,6 @@
#!/bin/bash
#-------------------------------------------------------------------------------
-# ONOS remote command-line client
+# ONOS remote command-line client.
#-------------------------------------------------------------------------------
[ -n "$1" ] && OCI=$1 && shift
diff --git a/tools/test/bin/onos-gui b/tools/test/bin/onos-gui
new file mode 100755
index 0000000..f782751
--- /dev/null
+++ b/tools/test/bin/onos-gui
@@ -0,0 +1,9 @@
+#!/bin/bash
+#-------------------------------------------------------------------------------
+# Launches ONOS GUI on the specified node.
+#-------------------------------------------------------------------------------
+
+host=${1:-$OCI}
+host=${host:-localhost}
+
+open http://$host:8181/onos/tvue
\ No newline at end of file
diff --git a/tools/test/bin/onos-install b/tools/test/bin/onos-install
index b270704..ecb6da1 100755
--- a/tools/test/bin/onos-install
+++ b/tools/test/bin/onos-install
@@ -1,6 +1,6 @@
#!/bin/bash
#-------------------------------------------------------------------------------
-# Remotely pushes bits to a remote machine and installs ONOS.
+# Remotely pushes bits to a remote node and installs ONOS on it.
#-------------------------------------------------------------------------------
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
diff --git a/tools/test/bin/onos-log b/tools/test/bin/onos-log
index 1a205f4..3e0c945 100755
--- a/tools/test/bin/onos-log
+++ b/tools/test/bin/onos-log
@@ -1,6 +1,6 @@
#!/bin/bash
#-------------------------------------------------------------------------------
-# Monitors remote ONOS log file.
+# Monitors remote ONOS log file on the specified node.
#-------------------------------------------------------------------------------
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
diff --git a/tools/test/bin/onos-push-keys b/tools/test/bin/onos-push-keys
index a469643..fd49f86 100755
--- a/tools/test/bin/onos-push-keys
+++ b/tools/test/bin/onos-push-keys
@@ -1,6 +1,6 @@
#!/bin/bash
#-------------------------------------------------------------------------------
-# Pushes the local id_rsa.pub to the remote ONOS host authorized_keys.
+# Pushes the local id_rsa.pub to the authorized_keys on a remote ONOS node.
#-------------------------------------------------------------------------------
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
diff --git a/tools/test/bin/onos-service b/tools/test/bin/onos-service
new file mode 100755
index 0000000..d148f67
--- /dev/null
+++ b/tools/test/bin/onos-service
@@ -0,0 +1,9 @@
+#!/bin/bash
+#-------------------------------------------------------------------------------
+# Remotely administers the ONOS service on the specified node.
+#-------------------------------------------------------------------------------
+
+[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
+. $ONOS_ROOT/tools/build/envDefaults
+
+ssh $ONOS_USER@${1:-$OCI} "sudo service onos ${2:-status}"
\ No newline at end of file
diff --git a/tools/test/bin/onos-ssh b/tools/test/bin/onos-ssh
index 406c9cb..f475f25 100755
--- a/tools/test/bin/onos-ssh
+++ b/tools/test/bin/onos-ssh
@@ -1,6 +1,6 @@
#!/bin/bash
#-------------------------------------------------------------------------------
-# Logs in to the remote ONOS instance.
+# Logs in to the remote ONOS node.
#-------------------------------------------------------------------------------
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
diff --git a/tools/test/bin/onos-test b/tools/test/bin/onos-test
index d549721..c5e8356 100755
--- a/tools/test/bin/onos-test
+++ b/tools/test/bin/onos-test
@@ -9,5 +9,5 @@
nodes=$(env | sort | egrep "OC[0-9]+" | cut -d= -f2)
onos-package
-for node in $nodes; do onos-install -f $node; done
+for node in $nodes; do printf "%s: " $node; onos-install -f $node; done
for node in $nodes; do onos-wait-for-start $node; done
diff --git a/tools/test/bin/onos-uninstall b/tools/test/bin/onos-uninstall
index bfc3b48..78ff629 100755
--- a/tools/test/bin/onos-uninstall
+++ b/tools/test/bin/onos-uninstall
@@ -1,6 +1,6 @@
#!/bin/bash
#-------------------------------------------------------------------------------
-# Remotely stops & uninstalls ONOS.
+# Remotely stops & uninstalls ONOS on the specified node.
#-------------------------------------------------------------------------------
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
diff --git a/tools/test/bin/onos-wait-for-start b/tools/test/bin/onos-wait-for-start
index 0190d6f..442a07d 100755
--- a/tools/test/bin/onos-wait-for-start
+++ b/tools/test/bin/onos-wait-for-start
@@ -1,6 +1,6 @@
#!/bin/bash
#-------------------------------------------------------------------------------
-# Waits for ONOS to reach run-level 100.
+# Waits for ONOS to reach run-level 100 on the specified remote node.
#-------------------------------------------------------------------------------
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1