From: Eduardo Ramos Testillano (eramedu) Date: Mon, 27 Apr 2020 01:54:56 +0000 (+0200) Subject: ADML is not really an AOTS deployment but an simple ADML one X-Git-Url: https://git.teslayout.com/public/public/public/?a=commitdiff_plain;h=d7b32ee56cf86c7702943d6afbac34c668b023ed;p=anna.git ADML is not really an AOTS deployment but an simple ADML one It has http support --- diff --git a/INSTALL_AOTS.md b/INSTALL_AOTS.md index 021707b..5da6589 100644 --- a/INSTALL_AOTS.md +++ b/INSTALL_AOTS.md @@ -6,10 +6,6 @@ Execute 'example/diameter/launcher/deploy-aots.sh' and follow instructions. -### AOTS ADML Agent - -Execute 'example/diameter/launcher/deploy-aots-adml.sh' and follow instructions. - ## Documentation See README.md file at installation target directory. diff --git a/example/diameter/launcher/deploy-adml-http.sh b/example/diameter/launcher/deploy-adml-http.sh new file mode 100755 index 0000000..3ee0e58 --- /dev/null +++ b/example/diameter/launcher/deploy-adml-http.sh @@ -0,0 +1,119 @@ +#!/bin/bash + +############# +# VARIABLES # +############# +SCR_DIR=`readlink -f $0 | xargs dirname` +PROJECT_ROOT=$(readlink -f $SCR_DIR/../../..) + +############# +# FUNCTIONS # +############# +_exit () { + local msg="$1" + local rc=$2 + [ -z "$rc" ] && rc=1 + + # Exit message: + [ -n "$msg" ] && echo -e "\n${msg}\n" + + exit $rc +} + +############# +# EXECUTION # +############# + +echo +echo "------------------------------------------------------" +echo " ADML with HTTP support installation " +echo "------------------------------------------------------" +echo +[ -d $PROJECT_ROOT/build/Release ] && VARIANT=Release +[ -d $PROJECT_ROOT/build/Debug ] && VARIANT=Debug +[ -z "$VARIANT" ] && _exit "Cannot locate neither 'Release' nor 'Debug' variant !" +build_type_letter=$(echo $VARIANT | cut -c1 | tr '[:upper:]' '[:lower:]') + +version__dflt=v"`date +'%y'`.`date +'%m'`.`date +'%d'`$build_type_letter" +INSTALL__dflt=$HOME/3rdParty/anna-adml-http-builds/v"`date +'%y'`.`date +'%m'`.`date +'%d'`$build_type_letter" + +echo "Choose the target path for installation [$INSTALL__dflt]:" +echo " (enter a non-existent directory)" +read INSTALL +[ -z "$INSTALL" ] && INSTALL=$INSTALL__dflt +INSTALL=`readlink -m $INSTALL` +[ -d $INSTALL ] && _exit "The target installation directory ($INSTALL) already exists ! (if you want to reinstall, remove it first)" + +echo +echo "Stage 1: Deploying resources ......................" +echo +mkdir -p $INSTALL +cp -rL $SCR_DIR/deployments/adml/* $INSTALL + +# VARIABLES ###################################### +# Sources: +LDIR=${PROJECT_ROOT}/example/diameter/launcher +BIN_DIR=${PROJECT_ROOT}/build/$VARIANT/bin +LIB_DIR=${PROJECT_ROOT}/build/$VARIANT/lib + +# Targets: +ADML=${INSTALL} +DTDs=${ADML}/DTDs +DYNLIBS=${ADML}/dynlibs +################################################## + +echo +echo "Variant: $VARIANT" +echo + +# Empty directories: +mkdir -p ${ADML}/counters +mkdir -p ${ADML}/test-reports + +# Scripts: +cp ${PROJECT_ROOT}/example/diameter/launcher/resources/scripts/operation_curl.sh ${ADML}/operation.sh + +# Templates: +mkdir $DTDs +cp ${PROJECT_ROOT}/include/anna/diameter/codec/message.dtd ${DTDs} +cp ${PROJECT_ROOT}/include/anna/diameter/stack/dictionary.dtd ${DTDs} +cp ${PROJECT_ROOT}/example/diameter/launcher/resources/services_examples/services.dtd ${DTDs} + +# Main Launcher and dynamic libraries: +cp ${BIN_DIR}/anna_diameter_launcher ${ADML}/ADML +cp -r $LIB_DIR/dynamic/launcher ${DYNLIBS} +cp $LIB_DIR/libanna_testing_shared.so ${DYNLIBS} + +# Get stuff from leaf directories: +cd $LIB_DIR/dynamic/launcher +leafs=( $(find . -type d -links 2) ) +cd - >/dev/null + +cd ${PROJECT_ROOT}/dynamic/launcher +for dir in ${leafs[@]} +do + cp $dir/*.xml ${DYNLIBS}/$dir 2>/dev/null + cp $dir/dynamic.suffix ${DYNLIBS}/$dir 2>/dev/null + cp -r $dir/services ${DYNLIBS}/$dir 2>/dev/null +done +cd - >/dev/null + +# ADML dynamic libs selection script: +cp ${LDIR}/resources/scripts/select_dynlib.sh ${DYNLIBS}/select.sh + +# Default dynamic library: +cd ${DYNLIBS} +ln -sf default/libanna_launcher_procedure_default_shared.so +cd - >/dev/null + +# ADML Agent shall use http server: +httpOpt="--httpServer \`grep -v ^# .httpServer\`" +echo "${httpOpt}" >> ${ADML}/args.ft +echo "${httpOpt}" >> ${ADML}/args.st +echo "localhost:8000" > ${ADML}/.httpServer + +# Remove AOTS actions: +rm ${ADML}/ACTIONS.md + +_exit "Done!" 0 + diff --git a/example/diameter/launcher/deploy-aots-adml.sh b/example/diameter/launcher/deploy-aots-adml.sh deleted file mode 100755 index 4dc5aa6..0000000 --- a/example/diameter/launcher/deploy-aots-adml.sh +++ /dev/null @@ -1,116 +0,0 @@ -#!/bin/bash - -############# -# VARIABLES # -############# -SCR_DIR=`readlink -f $0 | xargs dirname` -PROJECT_ROOT=$(readlink -f $SCR_DIR/../../..) - -############# -# FUNCTIONS # -############# -_exit () { - local msg="$1" - local rc=$2 - [ -z "$rc" ] && rc=1 - - # Exit message: - [ -n "$msg" ] && echo -e "\n${msg}\n" - - exit $rc -} - -############# -# EXECUTION # -############# - -echo -echo "------------------------------------------------------" -echo " AOTS ADML Agent installation " -echo "------------------------------------------------------" -echo -[ -d $PROJECT_ROOT/build/Release ] && VARIANT=Release -[ -d $PROJECT_ROOT/build/Debug ] && VARIANT=Debug -[ -z "$VARIANT" ] && _exit "Cannot locate neither 'Release' nor 'Debug' variant !" -build_type_letter=$(echo $VARIANT | cut -c1 | tr '[:upper:]' '[:lower:]') - -version__dflt=v"`date +'%y'`.`date +'%m'`.`date +'%d'`$build_type_letter" -INSTALL__dflt=$HOME/3rdParty/anna-aots-adml-builds/v"`date +'%y'`.`date +'%m'`.`date +'%d'`$build_type_letter" - -echo "Choose the target path for installation [$INSTALL__dflt]:" -echo " (enter a non-existent directory)" -read INSTALL -[ -z "$INSTALL" ] && INSTALL=$INSTALL__dflt -INSTALL=`readlink -m $INSTALL` -[ -d $INSTALL ] && _exit "The target installation directory ($INSTALL) already exists ! (if you want to reinstall, remove it first)" - -echo -echo "Stage 1: Deploying resources ......................" -echo -mkdir -p $INSTALL -cp -rL $SCR_DIR/deployments/aots-adml/* $INSTALL - -# VARIABLES ###################################### -# Sources: -LDIR=${PROJECT_ROOT}/example/diameter/launcher -BIN_DIR=${PROJECT_ROOT}/build/$VARIANT/bin -LIB_DIR=${PROJECT_ROOT}/build/$VARIANT/lib - -# Targets: -ADML=${INSTALL} -DTDs=${ADML}/DTDs -DYNLIBS=${ADML}/dynlibs -################################################## - -echo -echo "Variant: $VARIANT" -echo - -# Empty directories: -mkdir -p ${ADML}/counters -mkdir -p ${ADML}/test-reports - -# Scripts: -cp ${PROJECT_ROOT}/example/diameter/launcher/resources/scripts/operation_curl.sh ${ADML}/operation.sh - -# Templates: -mkdir $DTDs -cp ${PROJECT_ROOT}/include/anna/diameter/codec/message.dtd ${DTDs} -cp ${PROJECT_ROOT}/include/anna/diameter/stack/dictionary.dtd ${DTDs} -cp ${PROJECT_ROOT}/example/diameter/launcher/resources/services_examples/services.dtd ${DTDs} - -# Main Launcher and dynamic libraries: -cp ${BIN_DIR}/anna_diameter_launcher ${ADML}/ADML -cp -r $LIB_DIR/dynamic/launcher ${DYNLIBS} -cp $LIB_DIR/libanna_testing_shared.so ${DYNLIBS} - -# Get stuff from leaf directories: -cd $LIB_DIR/dynamic/launcher -leafs=( $(find . -type d -links 2) ) -cd - >/dev/null - -cd ${PROJECT_ROOT}/dynamic/launcher -for dir in ${leafs[@]} -do - cp $dir/*.xml ${DYNLIBS}/$dir 2>/dev/null - cp $dir/dynamic.suffix ${DYNLIBS}/$dir 2>/dev/null - cp -r $dir/services ${DYNLIBS}/$dir 2>/dev/null -done -cd - >/dev/null - -# ADML dynamic libs selection script: -cp ${LDIR}/resources/scripts/select_dynlib.sh ${DYNLIBS}/select.sh - -# Default dynamic library: -cd ${DYNLIBS} -ln -sf default/libanna_launcher_procedure_default_shared.so -cd - >/dev/null - -# ADML Agent shall use http server: -httpOpt="--httpServer \`grep -v ^# .httpServer\`" -echo "${httpOpt}" >> ${ADML}/args.ft -echo "${httpOpt}" >> ${ADML}/args.st -echo "localhost:8000" > ${ADML}/.httpServer - -_exit "Done!" 0 - diff --git a/example/diameter/launcher/deployments/adml/ACTIONS.md b/example/diameter/launcher/deployments/adml/ACTIONS.md new file mode 100644 index 0000000..280b214 --- /dev/null +++ b/example/diameter/launcher/deployments/adml/ACTIONS.md @@ -0,0 +1,84 @@ +# ADML actions + +## send_xml_to_entity + +Sends a diameter message in xml format (see DTDs/message.dtd) as client to the server(s) configured. + +Arguments: xml[, answers_to] +* xml: the diameter message in xml format. +* answers_to: optional step number of a 'wait_xml_from_entity' for a request message. + Steps are the actions numbered from 1 to N +Example(1): +``` +- action: AF/send_xml_to_entity + xml: aar-initial.xml +``` + +Example(2): +``` +- action: AF/wait_xml_from_entity + arguments: + xml: dpr.xml + +- action: AF/send_xml_to_entity + arguments: + xml: dpa.xml + answers_to: 1 +``` + +## wait_xml_from_entity + +Waits a diameter message in xml format (see DTDs/message.dtd) as client from the server(s) connected. +Step blocks until match reception (regular expressions could be used). + +Arguments: xml +* xml: the diameter message in xml format. + +Example: +``` +- action: AFPC/wait_xml_from_entity + arguments: + xml: aaa.xml +``` + +## send_xml_to_client + +Sends a diameter message in xml format (see DTDs/message.dtd) as server to any client(s) connected. + +Arguments: xml[, answers_to] +* xml: the diameter message in xml format. +* answers_to: optional step number of a 'wait_xml_from_client' for a request message. + Steps are the actions numbered from 1 to N +Example(1): +``` +- action: AF/send_xml_to_client + arguments: + xml: dpr.xml +``` + +Example(2): +``` +- action: AFPC/wait_xml_from_client + xml: dpr.xml + arguments: + +- action: AFPC/send_xml_to_client + xml: dpa.xml + arguments: +``` + +## wait_xml_from_client + +Waits a diameter message in xml format (see DTDs/message.dtd) as server from the client(s) connected. +Step blocks until match reception (regular expressions could be used). + +Arguments: xml +* xml: the diameter message in xml format. + +Example: +``` +- action: AFPC/wait_xml_from_client + arguments: + xml: dpr.xml +``` + diff --git a/example/diameter/launcher/deployments/adml/HINTS.md b/example/diameter/launcher/deployments/adml/HINTS.md new file mode 100644 index 0000000..a9314e3 --- /dev/null +++ b/example/diameter/launcher/deployments/adml/HINTS.md @@ -0,0 +1,28 @@ +# ADML hints + +## AF-Application-Identifier + +Diameter RFC assigned the format 'OctetString' to this AVP although it is almost always intended to be human-readable. 'UTF8String' format could be more appropiate, but probably the intention was to avoid possible limits. + +ADML message codec shows readable data when possible using the field 'data'. When this is not possible, the 'hex-data' field will encode the information. The 'OctetString' format is hexadecimal by nature (string of octets), then always 'hex-data' will be shown for this kind of AVPs. + +For example: + + +You could decode using hex dump utility: 'xxd' + +$> echo "75726e25334175726e2d787878253341336770702d736572766963652e696d732e696373692e6d6d74656c" | xxd -p -r +$> urn%3Aurn-xxx%3A3gpp-service.ims.icsi.mmtel + +But the thing that you may probably need, is to encode a desired value into xml messages while designing a test case. For this situation, use the opossite (drop reverse flag '-r' to xxd): + +$> echo -n "urn%3Aurn-xxx%3A3gpp-service.ims.icsi.mmtel" | xxd -p | tr -d '\n' +$> 75726e25334175726e2d787878253341336770702d736572766963652e696d732e696373692e6d6d74656c + +or use 'od' (files dump) utility: + +$> echo -n "urn%3Aurn-xxx%3A3gpp-service.ims.icsi.mmtel" | od -A n -t x1 | tr -d ' ' | tr -d '\n' +$> 75726e25334175726e2d787878253341336770702d736572766963652e696d732e696373692e6d6d74656c + +The '-n' in the echo is neccessary to avoid encoding of carriage return (0x0a) for the string provided. + diff --git a/example/diameter/launcher/deployments/adml/args.ft b/example/diameter/launcher/deployments/adml/args.ft new file mode 100644 index 0000000..fa3411d --- /dev/null +++ b/example/diameter/launcher/deployments/adml/args.ft @@ -0,0 +1,21 @@ +# ADML will start with base protocol dictionary and no nodes on services.xml: +--services services.xml + +# Counters directory: +--cntDir counters +# Counters record procedure period in milliseconds. +# If missing, default value of 300000 (5 minutes) will be assigned. +# Zero value, disable the dump procedure. +#--cntRecordPeriod 10000 + +# System test: +--tmDir test-reports +# To override traffic logs configuration in order to be disabled for all the +# loaded nodes, launch the process by mean: './start.sh st' + +# Statistics: +--logStatisticSamples all + +# Add to take debug traces once started +--trace debug + diff --git a/example/diameter/launcher/deployments/adml/args.st b/example/diameter/launcher/deployments/adml/args.st new file mode 100644 index 0000000..733daaf --- /dev/null +++ b/example/diameter/launcher/deployments/adml/args.st @@ -0,0 +1,22 @@ +# ADML will start with base protocol dictionary and no nodes on services.xml: +--services services.xml + +# Counters directory: +--cntDir counters +# Counters record procedure period in milliseconds. +# If missing, default value of 300000 (5 minutes) will be assigned. +# Zero value, disable the dump procedure. +#--cntRecordPeriod 10000 + +# System test: +--tmDir test-reports +# To override traffic logs configuration in order to be disabled for all the +# loaded nodes, launch the process by mean: './start.sh st' + +# Statistics: +--logStatisticSamples all + +# Add to take debug traces once started +# --trace debug +--disableLogs + diff --git a/example/diameter/launcher/deployments/adml/services.xml.example b/example/diameter/launcher/deployments/adml/services.xml.example new file mode 100644 index 0000000..a54cf09 --- /dev/null +++ b/example/diameter/launcher/deployments/adml/services.xml.example @@ -0,0 +1,29 @@ + + + + + + + + diff --git a/example/diameter/launcher/deployments/adml/stacks b/example/diameter/launcher/deployments/adml/stacks new file mode 120000 index 0000000..b2773bc --- /dev/null +++ b/example/diameter/launcher/deployments/adml/stacks @@ -0,0 +1 @@ +../../resources/stack_examples \ No newline at end of file diff --git a/example/diameter/launcher/deployments/adml/start.sh b/example/diameter/launcher/deployments/adml/start.sh new file mode 100755 index 0000000..d2b371e --- /dev/null +++ b/example/diameter/launcher/deployments/adml/start.sh @@ -0,0 +1,21 @@ +#!/bin/bash +# $1: args type could be 'ft' (function test) or 'st' (system test). By default: ft +function pgrep_live { + pids=$(pgrep "$1"); + [ "$pids" ] || return; + ps -o s= -o pid= $pids | sed -n 's/^[^ZT][[:space:]]\+//p'; +} +cd `dirname $0` +ARGS=args.$1 +[ -z "$1" ] && ARGS=args.ft +STARTED=`pgrep_live ADML` +[ -n "$STARTED" ] && { echo "Already started !"; echo "PID $STARTED" ; exit 1 ; } +0> launcher.trace +for file in `ls *.launcher.log 2>/dev/null`; do 0> $file; done +mkdir -p counters test-reports +rm -f counters/* test-reports/* *.csv +export LD_LIBRARY_PATH=$PWD/dynlibs +eval ./ADML `grep -v ^# $ARGS` & +echo $! > .pid +echo "Done !" + diff --git a/example/diameter/launcher/deployments/adml/stop.sh b/example/diameter/launcher/deployments/adml/stop.sh new file mode 100755 index 0000000..a4f1121 --- /dev/null +++ b/example/diameter/launcher/deployments/adml/stop.sh @@ -0,0 +1,26 @@ +#!/bin/bash +function pgrep_live { + pids=$(pgrep "$1"); + [ "$pids" ] || return; + ps -o s= -o pid= $pids | sed -n 's/^[^ZT][[:space:]]\+//p'; +} +cd `dirname $0` +PID=$(pgrep_live ^ADML) +[ -z "$PID" ] && exit 0 +kill $PID + +# Protection to force kill (with SIGKILL) if ADML still alive after certain time: +seconds2force=3 +count=$((10*seconds2force)) +kill0=0 +while [ $kill0 -eq 0 -a $count -gt 0 ] +do + sleep 0.1 + count=$((count-1)) + kill -0 $PID 2>/dev/null + kill0=$? + echo -n . +done +[ $kill0 -eq 0 ] && { echo " sigkill to ADML pid $PID !" ; kill -9 $PID ; } +rm -f .pid + diff --git a/example/diameter/launcher/deployments/aots-adml/ACTIONS.md b/example/diameter/launcher/deployments/aots-adml/ACTIONS.md deleted file mode 100644 index 280b214..0000000 --- a/example/diameter/launcher/deployments/aots-adml/ACTIONS.md +++ /dev/null @@ -1,84 +0,0 @@ -# ADML actions - -## send_xml_to_entity - -Sends a diameter message in xml format (see DTDs/message.dtd) as client to the server(s) configured. - -Arguments: xml[, answers_to] -* xml: the diameter message in xml format. -* answers_to: optional step number of a 'wait_xml_from_entity' for a request message. - Steps are the actions numbered from 1 to N -Example(1): -``` -- action: AF/send_xml_to_entity - xml: aar-initial.xml -``` - -Example(2): -``` -- action: AF/wait_xml_from_entity - arguments: - xml: dpr.xml - -- action: AF/send_xml_to_entity - arguments: - xml: dpa.xml - answers_to: 1 -``` - -## wait_xml_from_entity - -Waits a diameter message in xml format (see DTDs/message.dtd) as client from the server(s) connected. -Step blocks until match reception (regular expressions could be used). - -Arguments: xml -* xml: the diameter message in xml format. - -Example: -``` -- action: AFPC/wait_xml_from_entity - arguments: - xml: aaa.xml -``` - -## send_xml_to_client - -Sends a diameter message in xml format (see DTDs/message.dtd) as server to any client(s) connected. - -Arguments: xml[, answers_to] -* xml: the diameter message in xml format. -* answers_to: optional step number of a 'wait_xml_from_client' for a request message. - Steps are the actions numbered from 1 to N -Example(1): -``` -- action: AF/send_xml_to_client - arguments: - xml: dpr.xml -``` - -Example(2): -``` -- action: AFPC/wait_xml_from_client - xml: dpr.xml - arguments: - -- action: AFPC/send_xml_to_client - xml: dpa.xml - arguments: -``` - -## wait_xml_from_client - -Waits a diameter message in xml format (see DTDs/message.dtd) as server from the client(s) connected. -Step blocks until match reception (regular expressions could be used). - -Arguments: xml -* xml: the diameter message in xml format. - -Example: -``` -- action: AFPC/wait_xml_from_client - arguments: - xml: dpr.xml -``` - diff --git a/example/diameter/launcher/deployments/aots-adml/HINTS.md b/example/diameter/launcher/deployments/aots-adml/HINTS.md deleted file mode 100644 index a9314e3..0000000 --- a/example/diameter/launcher/deployments/aots-adml/HINTS.md +++ /dev/null @@ -1,28 +0,0 @@ -# ADML hints - -## AF-Application-Identifier - -Diameter RFC assigned the format 'OctetString' to this AVP although it is almost always intended to be human-readable. 'UTF8String' format could be more appropiate, but probably the intention was to avoid possible limits. - -ADML message codec shows readable data when possible using the field 'data'. When this is not possible, the 'hex-data' field will encode the information. The 'OctetString' format is hexadecimal by nature (string of octets), then always 'hex-data' will be shown for this kind of AVPs. - -For example: - - -You could decode using hex dump utility: 'xxd' - -$> echo "75726e25334175726e2d787878253341336770702d736572766963652e696d732e696373692e6d6d74656c" | xxd -p -r -$> urn%3Aurn-xxx%3A3gpp-service.ims.icsi.mmtel - -But the thing that you may probably need, is to encode a desired value into xml messages while designing a test case. For this situation, use the opossite (drop reverse flag '-r' to xxd): - -$> echo -n "urn%3Aurn-xxx%3A3gpp-service.ims.icsi.mmtel" | xxd -p | tr -d '\n' -$> 75726e25334175726e2d787878253341336770702d736572766963652e696d732e696373692e6d6d74656c - -or use 'od' (files dump) utility: - -$> echo -n "urn%3Aurn-xxx%3A3gpp-service.ims.icsi.mmtel" | od -A n -t x1 | tr -d ' ' | tr -d '\n' -$> 75726e25334175726e2d787878253341336770702d736572766963652e696d732e696373692e6d6d74656c - -The '-n' in the echo is neccessary to avoid encoding of carriage return (0x0a) for the string provided. - diff --git a/example/diameter/launcher/deployments/aots-adml/args.ft b/example/diameter/launcher/deployments/aots-adml/args.ft deleted file mode 100644 index fa3411d..0000000 --- a/example/diameter/launcher/deployments/aots-adml/args.ft +++ /dev/null @@ -1,21 +0,0 @@ -# ADML will start with base protocol dictionary and no nodes on services.xml: ---services services.xml - -# Counters directory: ---cntDir counters -# Counters record procedure period in milliseconds. -# If missing, default value of 300000 (5 minutes) will be assigned. -# Zero value, disable the dump procedure. -#--cntRecordPeriod 10000 - -# System test: ---tmDir test-reports -# To override traffic logs configuration in order to be disabled for all the -# loaded nodes, launch the process by mean: './start.sh st' - -# Statistics: ---logStatisticSamples all - -# Add to take debug traces once started ---trace debug - diff --git a/example/diameter/launcher/deployments/aots-adml/args.st b/example/diameter/launcher/deployments/aots-adml/args.st deleted file mode 100644 index 733daaf..0000000 --- a/example/diameter/launcher/deployments/aots-adml/args.st +++ /dev/null @@ -1,22 +0,0 @@ -# ADML will start with base protocol dictionary and no nodes on services.xml: ---services services.xml - -# Counters directory: ---cntDir counters -# Counters record procedure period in milliseconds. -# If missing, default value of 300000 (5 minutes) will be assigned. -# Zero value, disable the dump procedure. -#--cntRecordPeriod 10000 - -# System test: ---tmDir test-reports -# To override traffic logs configuration in order to be disabled for all the -# loaded nodes, launch the process by mean: './start.sh st' - -# Statistics: ---logStatisticSamples all - -# Add to take debug traces once started -# --trace debug ---disableLogs - diff --git a/example/diameter/launcher/deployments/aots-adml/services.xml.example b/example/diameter/launcher/deployments/aots-adml/services.xml.example deleted file mode 100644 index a54cf09..0000000 --- a/example/diameter/launcher/deployments/aots-adml/services.xml.example +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - - diff --git a/example/diameter/launcher/deployments/aots-adml/stacks b/example/diameter/launcher/deployments/aots-adml/stacks deleted file mode 120000 index b2773bc..0000000 --- a/example/diameter/launcher/deployments/aots-adml/stacks +++ /dev/null @@ -1 +0,0 @@ -../../resources/stack_examples \ No newline at end of file diff --git a/example/diameter/launcher/deployments/aots-adml/start.sh b/example/diameter/launcher/deployments/aots-adml/start.sh deleted file mode 100755 index d2b371e..0000000 --- a/example/diameter/launcher/deployments/aots-adml/start.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash -# $1: args type could be 'ft' (function test) or 'st' (system test). By default: ft -function pgrep_live { - pids=$(pgrep "$1"); - [ "$pids" ] || return; - ps -o s= -o pid= $pids | sed -n 's/^[^ZT][[:space:]]\+//p'; -} -cd `dirname $0` -ARGS=args.$1 -[ -z "$1" ] && ARGS=args.ft -STARTED=`pgrep_live ADML` -[ -n "$STARTED" ] && { echo "Already started !"; echo "PID $STARTED" ; exit 1 ; } -0> launcher.trace -for file in `ls *.launcher.log 2>/dev/null`; do 0> $file; done -mkdir -p counters test-reports -rm -f counters/* test-reports/* *.csv -export LD_LIBRARY_PATH=$PWD/dynlibs -eval ./ADML `grep -v ^# $ARGS` & -echo $! > .pid -echo "Done !" - diff --git a/example/diameter/launcher/deployments/aots-adml/stop.sh b/example/diameter/launcher/deployments/aots-adml/stop.sh deleted file mode 100755 index a4f1121..0000000 --- a/example/diameter/launcher/deployments/aots-adml/stop.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash -function pgrep_live { - pids=$(pgrep "$1"); - [ "$pids" ] || return; - ps -o s= -o pid= $pids | sed -n 's/^[^ZT][[:space:]]\+//p'; -} -cd `dirname $0` -PID=$(pgrep_live ^ADML) -[ -z "$PID" ] && exit 0 -kill $PID - -# Protection to force kill (with SIGKILL) if ADML still alive after certain time: -seconds2force=3 -count=$((10*seconds2force)) -kill0=0 -while [ $kill0 -eq 0 -a $count -gt 0 ] -do - sleep 0.1 - count=$((count-1)) - kill -0 $PID 2>/dev/null - kill0=$? - echo -n . -done -[ $kill0 -eq 0 ] && { echo " sigkill to ADML pid $PID !" ; kill -9 $PID ; } -rm -f .pid - diff --git a/example/diameter/launcher/deployments/aots-setup/agents/ADML b/example/diameter/launcher/deployments/aots-setup/agents/ADML index 703e402..a91053a 120000 --- a/example/diameter/launcher/deployments/aots-setup/agents/ADML +++ b/example/diameter/launcher/deployments/aots-setup/agents/ADML @@ -1 +1 @@ -../../aots-adml \ No newline at end of file +../../adml \ No newline at end of file