8 STD_DICTIONARY=stacks/avps_etsi.xml,stacks/avps_ietf.xml,stacks/avps_tgpp.xml,stacks/commands_baseProtocol.xml
9 APP_DICTIONARY=stacks/commands_qosControl.xml
10 DICTIONARY=$STD_DICTIONARY,$APP_DICTIONARY
12 # Communication endpoints:
13 LOCAL_STANDARD_ENDPOINT=localhost:3868
14 EXAMPLE_ENTITY_4_BALANCER=192.168.12.11:3868,192.168.12.21:3868
37 STARTED=\`pgrep $1 2>/dev/null\`
38 [ \$? -eq 0 ] && { echo "Already started!"; echo "\$STARTED" ; exit 1 ; }
49 # $1: input option (c, s, b, d)
50 # Retuns the type of launcher logical name for the input option
52 [ "$1" = "c" ] && echo client
53 [ "$1" = "s" ] && echo server
54 [ "$1" = "b" ] && echo balancer
55 [ "$1" = "d" ] && echo dummy
65 echo "Configure a (c)lient, (s)erver, (b)alancer or (d)ummy [c]:"
67 [ "$option" = "" ] && option=c
68 tol=$(get_tol $option)
69 [ "$tol" = "" ] && _exit "Option '$option' not implemented !!"
72 TRACING="-cntDir counters"
74 echo "Enable debug traces ? (y/n) [n]:"
76 [ "$enable" = "" ] && enable=n
77 [ "$enable" = "y" ] && TRACING="$TRACING -trace debug"
82 echo "Strict xml for decoded messages ? (y/n) [y]:"
83 echo " (ignoring flags turns a made-up xml representation; execute './$EXE_BN | grep -A1 ignoreFlags:' for more help)"
85 [ "$strict" = "" ] && strict=y
86 [ "$strict" = "n" ] && KINDNESS="-ignoreFlags"
87 if [ "$option" = "s" ]
90 echo "Ignore errors ? (y/n) [n]:"
91 echo " (ignoring errors, the process won't answer Failed-AVP automatically; execute './$EXE_BN | grep -A1 ignoreErrors:' for more help)"
93 [ "$i_errors" = "" ] && i_errors=n
94 [ "$i_errors" = "y" ] && KINDNESS="$KINDNESS -ignoreErrors"
99 ln -sf $EXE_BN $EXE_LINK
104 ENTITY=$LOCAL_STANDARD_ENDPOINT
105 createRunScript $EXE_LINK -dictionary $DICTIONARY -entity $ENTITY -entityServerSessions $CONNS -diameterServerSessions 0 $KINDNESS $TRACING &
109 SERVER=$LOCAL_STANDARD_ENDPOINT
110 createRunScript $EXE_LINK -dictionary $DICTIONARY -diameterServer $SERVER -diameterServerSessions $CONNS -entityServerSessions 0 $KINDNESS $TRACING &
114 SERVER=$LOCAL_STANDARD_ENDPOINT
115 ENTITY=$EXAMPLE_ENTITY_4_BALANCER
116 createRunScript $EXE_LINK -dictionary $DICTIONARY -entity $ENTITY -entityServerSessions $CONNS -diameterServer $SERVER -diameterServerSessions $CONNS -balance $KINDNESS $TRACING &
120 createRunScript $EXE_LINK -dictionary $DICTIONARY -entityServerSessions 0 -diameterServerSessions 0 $KINDNESS $TRACING &
126 echo "Created 'run.sh' script !"