aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/scripts')
-rw-r--r--src/main/scripts/VESrestfulCollector.sh (renamed from src/main/scripts/SErestfulCollector.sh)14
-rw-r--r--src/main/scripts/VESrestfulCollector_Status.sh41
2 files changed, 48 insertions, 7 deletions
diff --git a/src/main/scripts/SErestfulCollector.sh b/src/main/scripts/VESrestfulCollector.sh
index 9d39c16..a6d2d27 100644
--- a/src/main/scripts/SErestfulCollector.sh
+++ b/src/main/scripts/VESrestfulCollector.sh
@@ -21,7 +21,7 @@
###
usage() {
- echo "SErestfulCollector.sh <start/stop>"
+ echo "VESrestfulCollector.sh <start/stop>"
}
@@ -29,7 +29,7 @@ collector_start() {
collectorPid=`pgrep -f org.openecomp.dcae.commonFunction`
if [ ! -z "$collectorPid" ]; then
- echo "WARNING: Restful Standard Event Collector already running as PID $collectorPid";
+ echo "WARNING: VES Restful Collector already running as PID $collectorPid";
echo "Startup Aborted!!!"
exit 1
fi
@@ -50,9 +50,9 @@ collector_start() {
# run java. The classpath is the etc dir for config files, and the lib dir
# for all the jars.
- nohup $JAVA -cp "etc${PATHSEP}lib/*" $JAVA_OPTS $MAINCLASS $* &
+ nohup $JAVA -cp "etc${PATHSEP}lib/*" $JAVA_OPTS -Dhttps.protocols=TLSv1.1,TLSv1.2 $MAINCLASS $* &
if [ $? -ne 0 ]; then
- echo "Restful Standard Event Collector has been started!!!"
+ echo "VES Restful Collector has been started!!!"
fi
@@ -66,12 +66,12 @@ collector_stop() {
kill -9 $collectorPid
sleep 5
if [ ! "$(pgrep -f org.openecomp.dcae.commonFunction)" ]; then
- echo "Restful Standard Event Collector has been stopped!!!"
+ echo "VES Restful Collector has been stopped!!!"
else
- echo "Restful Standard Event Collector is being stopped!!!"
+ echo "VES Restful Collector is being stopped!!!"
fi
else
- echo "WARNING: No Restful Standard Event Collector is currently running";
+ echo "WARNING: No VES Collector instance is currently running";
exit 1
fi
diff --git a/src/main/scripts/VESrestfulCollector_Status.sh b/src/main/scripts/VESrestfulCollector_Status.sh
new file mode 100644
index 0000000..0365bc2
--- /dev/null
+++ b/src/main/scripts/VESrestfulCollector_Status.sh
@@ -0,0 +1,41 @@
+###
+# ============LICENSE_START=======================================================
+# PROJECT
+# ================================================================================
+# Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+# ================================================================================
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# ============LICENSE_END=========================================================
+###
+
+#!/bin/sh
+
+#secPid=`pgrep -f com.att.dcae.commonFunction.CommonStartup` --> master
+secPid=`pgrep -f org.openecomp.dcae.commonFunction.CommonStartup`
+
+
+if [ "${secPid}" ]
+then
+ #errorcnt = `grep -c "CambriaSimplerBatchPublisher - Send failed" ../logs/collector.log`
+ errorcnt=`tail -1000 ../logs/collector.log | grep -c "CambriaSimplerBatchPublisher - Send failed"`
+
+ if [ $errorcnt -gt 10 ]
+ then
+ echo "VESCollecter_Is_HavingError to publish"
+ else
+ echo "VESCollecter_Is_Running as PID $secPid"
+ fi
+else
+ echo "VESCollecter_Is_Not_Running"
+fi
+exit