diff options
author | Kajur, Harish (vk250x) <vk250x@att.com> | 2018-08-12 23:40:04 -0400 |
---|---|---|
committer | Kajur, Harish (vk250x) <vk250x@att.com> | 2018-08-13 02:49:05 -0400 |
commit | 538aad3add38a0ce4ef6ac25333d50bba7b05ac5 (patch) | |
tree | b0155c033b80bb6d6d316bd92cd5f280e4542e56 /aai-resources/src/main/scripts/common_functions.sh | |
parent | 96b7ed4bff9a2259f1f28f288caa6cc11c97db59 (diff) |
Update resources ms to use ingest library
Change the code to replace ModelIngestor
with the NodeIngestor and replace the EdgeRules
with the EdgeIngestor and EdgeSerializer
Edge Ingestor for getting the rules from json files
Edge Serializer for creating the edges between vertexes
Node Ingestor is responsible for the multiple oxm files
Issue-ID: AAI-1462
Change-Id: I555916911dc4076ac017173d63478b3b76b36e42
Signed-off-by: Kajur, Harish (vk250x) <vk250x@att.com>
Diffstat (limited to 'aai-resources/src/main/scripts/common_functions.sh')
-rw-r--r-- | aai-resources/src/main/scripts/common_functions.sh | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/aai-resources/src/main/scripts/common_functions.sh b/aai-resources/src/main/scripts/common_functions.sh index 768a911..9c8e275 100644 --- a/aai-resources/src/main/scripts/common_functions.sh +++ b/aai-resources/src/main/scripts/common_functions.sh @@ -1,4 +1,4 @@ -#!/bin/ksh +#!/bin/bash # # ============LICENSE_START======================================================= # org.onap.aai @@ -49,15 +49,24 @@ execute_spring_jar(){ shift 2; - EXECUTABLE_JAR=$(ls ${PROJECT_HOME}/lib/aai-resources-*.jar); + EXECUTABLE_JAR=$(ls ${PROJECT_HOME}/lib/*.jar); - JAVA_OPTS="${JAVA_PRE_OPTS}"; - JAVA_OPTS="-DAJSC_HOME=$PROJECT_HOME"; + JAVA_OPTS="${JAVA_PRE_OPTS} -DAJSC_HOME=$PROJECT_HOME"; JAVA_OPTS="$JAVA_OPTS -DBUNDLECONFIG_DIR=resources"; JAVA_OPTS="$JAVA_OPTS -Daai.home=$PROJECT_HOME "; JAVA_OPTS="$JAVA_OPTS -Dhttps.protocols=TLSv1.1,TLSv1.2"; JAVA_OPTS="$JAVA_OPTS -Dloader.main=${className}"; + JAVA_OPTS="$JAVA_OPTS -Dloader.path=${PROJECT_HOME}/resources"; JAVA_OPTS="$JAVA_OPTS -Dlogback.configurationFile=${logbackFile}"; + + export SOURCE_NAME=$(grep '^schema.source.name=' ${PROJECT_HOME}/resources/application.properties | cut -d"=" -f2-); + # Needed for the schema ingest library beans + eval $(grep '^schema\.' ${PROJECT_HOME}/resources/application.properties | \ + sed 's/^\(.*\)$/JAVA_OPTS="$JAVA_OPTS -D\1"/g' | \ + sed 's/${server.local.startpath}/${PROJECT_HOME}\/resources/g'| \ + sed 's/${schema.source.name}/'${SOURCE_NAME}'/g'\ + ) + JAVA_OPTS="${JAVA_OPTS} ${JAVA_POST_OPTS}"; ${JAVA_HOME}/bin/java ${JVM_OPTS} ${JAVA_OPTS} -jar ${EXECUTABLE_JAR} "$@" |