Params such as number of threads, Queue sizes, Heap size
are now configurable when deploying Gizmo
Change-Id: Ib58ff9cdf9e96378db7feaf3e7168267d05fd1e9
Issue-ID: AAI-807
Signed-off-by: sblimkie <steven.blimkie@amdocs.com>
-#Copyright (c) 2016 AT&T Intellectual Property. All rights reserved.
#This file is used for defining AJSC system properties for different configuration schemes and is necessary for the AJSC to run properly.
#The sys-props.properties file is used for running locally. The template.sys-props.properties file will be used when deployed
#to a SOA/CSI Cloud node.
#This file is used for defining AJSC system properties for different configuration schemes and is necessary for the AJSC to run properly.
#The sys-props.properties file is used for running locally. The template.sys-props.properties file will be used when deployed
#to a SOA/CSI Cloud node.
CONTINUE_ON_LISTENER_EXCEPTION=false
#Jetty Container ThreadCount Configuration Variables
CONTINUE_ON_LISTENER_EXCEPTION=false
#Jetty Container ThreadCount Configuration Variables
-AJSC_JETTY_ThreadCount_MIN=1
+AJSC_JETTY_ThreadCount_MIN=10
AJSC_JETTY_ThreadCount_MAX=200
AJSC_JETTY_ThreadCount_MAX=200
+AJSC_JETTY_BLOCKING_QUEUE_SIZE=200
AJSC_JETTY_IDLETIME_MAX=3000
#Camel Context level default threadPool Profile configuration
AJSC_JETTY_IDLETIME_MAX=3000
#Camel Context level default threadPool Profile configuration
#AJSC_EXTERNAL_PROPERTIES_FOLDERS=__basedir__/ajsc-shared-config/etc
#End of AJSC System Properties
#AJSC_EXTERNAL_PROPERTIES_FOLDERS=__basedir__/ajsc-shared-config/etc
#End of AJSC System Properties
-#Service System Properties. Please, place any Service related System Properties below.
+# This is the default keystore password for the example keystore included in the test-config
+# repository. It can be overwritten using the deploy.yaml env params
+KEY_STORE_PASSWORD=OBF:1y0q1uvc1uum1uvg1pil1pjl1uuq1uvk1uuu1y10
+KEY_MANAGER_PASSWORD=OBF:1y0q1uvc1uum1uvg1pil1pjl1uuq1uvk1uuu1y10
BASEDIR="/opt/app/crud-api/"
AJSC_HOME="$BASEDIR"
AJSC_CONF_HOME="$AJSC_HOME/bundleconfig/"
BASEDIR="/opt/app/crud-api/"
AJSC_HOME="$BASEDIR"
AJSC_CONF_HOME="$AJSC_HOME/bundleconfig/"
+# List of ajsc properties which are exposed for modification at deploy time
+declare -a MODIFY_PROP_LIST=("KEY_STORE_PASSWORD"
+ "KEY_MANAGER_PASSWORD"
+ "AJSC_JETTY_ThreadCount_MIN"
+ "AJSC_JETTY_ThreadCount_MAX"
+ "AJSC_JETTY_BLOCKING_QUEUE_SIZE")
+PROP_LIST_LENGTH=${#MODIFY_PROP_LIST[@]}
+
+for (( i=1; i<${PROP_LIST_LENGTH}+1; i++ ));
+do
+ PROP_NAME=${MODIFY_PROP_LIST[$i-1]}
+ PROP_VALUE=${!PROP_NAME}
+ if [ ! -z "$PROP_VALUE" ]; then
+ sed -i "s/$PROP_NAME.*$/$PROP_NAME=$PROP_VALUE/g" $AJSC_CONF_HOME/etc/sysprops/sys-props.properties
+ fi
+done
+
if [ -z "$CONFIG_HOME" ]; then
echo "CONFIG_HOME must be set in order to start up process"
exit 1
fi
if [ -z "$CONFIG_HOME" ]; then
echo "CONFIG_HOME must be set in order to start up process"
exit 1
fi
-if [ -z "$KEY_STORE_PASSWORD" ]; then
- echo "KEY_STORE_PASSWORD must be set in order to start up process"
- exit 1
-else
- echo "KEY_STORE_PASSWORD=$KEY_STORE_PASSWORD\n" >> $AJSC_CONF_HOME/etc/sysprops/sys-props.properties
-fi
-
-if [ -z "$KEY_MANAGER_PASSWORD" ]; then
- echo "KEY_MANAGER_PASSWORD must be set in order to start up process"
- exit 1
-else
- echo "KEY_MANAGER_PASSWORD=$KEY_MANAGER_PASSWORD\n" >> $AJSC_CONF_HOME/etc/sysprops/sys-props.properties
-fi
-
# Add any spring bean configuration files to the Gizmo deployment
if [ -n "$SERVICE_BEANS" ]; then
echo "Adding the following dynamic service beans to the deployment: "
# Add any spring bean configuration files to the Gizmo deployment
if [ -n "$SERVICE_BEANS" ]; then
echo "Adding the following dynamic service beans to the deployment: "