diff options
author | 2018-10-22 02:26:04 -0400 | |
---|---|---|
committer | 2018-10-24 14:57:42 -0400 | |
commit | 4a9119a27c8e41de6ccada46e3306a53a55ef881 (patch) | |
tree | 33cedcd21673efa8fe578c746bb8839e09e45ac5 | |
parent | 1344ef2dd571923b5fa40f7c0863477df59d651b (diff) |
Update logging for tests.
More logging
Longer Delay for TOMCAT
More Delays
Change-Id: I95b7dc4921fed6337c837b3ebd99251157a2d44e
Issue-ID: MUSIC-138
Signed-off-by: Thomas Nelson <nelson24@att.com>
-rwxr-xr-x | plans/music/music-test-plan/setup.sh | 27 |
1 files changed, 20 insertions, 7 deletions
diff --git a/plans/music/music-test-plan/setup.sh b/plans/music/music-test-plan/setup.sh index f8d950e4..add34b1a 100755 --- a/plans/music/music-test-plan/setup.sh +++ b/plans/music/music-test-plan/setup.sh @@ -25,12 +25,12 @@ source ${WORKSPACE}/scripts/music/music-scripts/music_script.sh # add here all the configuration steps eventually needed to be carried out for music CSIT testing # echo "########## music configuration step ##########"; -CASS_IMG=nexus3.onap.org:10001/onap/music/cassandra_3_11:latest -CASS_IMG_JOB=nexus3.onap.org:10001/onap/music/cassandra_job:latest +CASS_IMG=nexus3.onap.org:10001/onap/music/cassandra_3_11:3.0.23 +CASS_IMG_JOB=nexus3.onap.org:10001/onap/music/cassandra_job:3.0.23 TOMCAT_IMG=nexus3.onap.org:10001/library/tomcat:8.5 ZK_IMG=nexus3.onap.org:10001/library/zookeeper:3.4 BUSYBOX_IMG=nexus3.onap.org:10001/library/busybox:latest -MUSIC_IMG=nexus3.onap.org:10001/onap/music/music:latest +MUSIC_IMG=nexus3.onap.org:10001/onap/music/music:3.0.23 TT=10 WORK_DIR=/tmp/music CASS_USERNAME=nelson24 @@ -77,11 +77,11 @@ echo "########## Running Test to see if Cassandra is up ##########" docker run --name music-casstest --network music-net \ $BUSYBOX_IMG sh -c "until nc -z music-db 9042 && echo "success"; do echo 'No connection .. Sleeping for $TT seconds';sleep $TT; done;" +# Sleep 60 seconds to ensure Cassandra is up and running. +sleep 60; # Check to see if Keyspaces are there. docker exec music-db cqlsh -u cassandra -p cassandra -e "DESCRIBE keyspaces;" -sleep 10; - # Load data into Cassandra via Cassandra Job echo "########## Running Cassandra Job (music-job) to load cql files ##########" docker run -d --name music-job --network music-net \ @@ -92,10 +92,23 @@ docker run -d --name music-job --network music-net \ -e CASS_HOSTNAME=music-db \ -e USERNAME=$CASS_USERNAME \ -e PASSWORD=$CASS_PASSWORD \ -$CASS_IMG_JOB +$CASS_IMG_JOB + +sleep 70; + # Logs echo "########## Cassandra Job logs ##########" docker logs music-job +# Check to see if Keyspaces are there. +# "############## Check if new username and password work ##########" +docker exec music-db cqlsh -u $CASS_USERNAME -p $CASS_PASSWORD -e "DESCRIBE keyspaces;" +# Check to see if Keyspaces are there. +# "############## Check if original username and password work ##########" +docker exec music-db cqlsh -u cassandra -p cassandra -e "DESCRIBE keyspaces;" +# Check to see if Keyspaces are there. +# "############## Check if new cassandra username and password work ##########" +docker exec music-db cqlsh -u cassandra -p SomeLongRandomStringNoonewillthinkof -e "DESCRIBE keyspaces;" + # Start Music war echo "########## Start music-war ##########" @@ -109,7 +122,7 @@ ZOO_IP=`docker inspect -f '{{ $network := index .NetworkSettings.Networks "music echo "ZOOKEEPER_IP=${ZOO_IP}" # Delay between Cassandra/Zookeeper and Tomcat -sleep 10; +sleep 120; # Start Up tomcat - Needs to have properties,logs dir and war file volume mapped. echo "########## Start Tomcat (music-tomcat) ##########" |