Skip to content

Commit 9c6788f

Browse files
author
Tom Barnes
committed
rename traceUtils.py and traceUtils.sh to utils.py and utils.sh
1 parent 0fd8d92 commit 9c6788f

File tree

17 files changed

+33
-31
lines changed

17 files changed

+33
-31
lines changed

operator/src/main/resources/scripts/introspectDomain.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
import re
8888
from datetime import datetime
8989

90-
# Include this script's current directory in the import path (so we can import traceUtils, etc.)
90+
# Include this script's current directory in the import path (so we can import utils, etc.)
9191
# sys.path.append('/weblogic-operator/scripts')
9292

9393
# Alternative way to dynamically get script's current directory
@@ -96,7 +96,7 @@
9696
tmp_scriptdir=os.path.dirname(tmp_info[0])
9797
sys.path.append(tmp_scriptdir)
9898

99-
from traceUtils import *
99+
from utils import *
100100

101101
class OfflineWlstEnv(object):
102102

operator/src/main/resources/scripts/introspectDomain.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
4040

4141
# setup tracing
4242

43-
source ${SCRIPTPATH}/traceUtils.sh
44-
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/traceUtils.sh" && exit 1
43+
source ${SCRIPTPATH}/utils.sh
44+
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/utils.sh" && exit 1
4545

4646
trace "Introspecting the domain"
4747

operator/src/main/resources/scripts/livenessProbe.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
RETVAL=$(test -f /weblogic-operator/debug/livenessProbeSuccessOverride ; echo $?)
1313

1414
SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
15-
source ${SCRIPTPATH}/traceUtils.sh
16-
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/traceUtils.sh" && exit $RETVAL
15+
source ${SCRIPTPATH}/utils.sh
16+
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/utils.sh" && exit $RETVAL
1717

1818
# check DOMAIN_HOME for a config/config.xml, reset DOMAIN_HOME if needed:
1919
exportEffectiveDomainHome || exit $RETVAL

operator/src/main/resources/scripts/monitorLog.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
echo $$ > /tmp/monitorLog-pid
1515

1616
SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
17-
source ${SCRIPTPATH}/traceUtils.sh
17+
source ${SCRIPTPATH}/utils.sh
1818

1919
trace "Monitoring server log file $1 every $2 seconds for selected known log messages."
2020

operator/src/main/resources/scripts/readState.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
# file which is updated by the node manager.
99

1010
SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
11-
source ${SCRIPTPATH}/traceUtils.sh
12-
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/traceUtils.sh" && exit 1
11+
source ${SCRIPTPATH}/utils.sh
12+
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/utils.sh" && exit 1
1313

1414
# check DOMAIN_HOME for a config/config.xml, reset DOMAIN_HOME if needed:
1515
exportEffectiveDomainHome || exit 1

operator/src/main/resources/scripts/startNodeManager.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@
4747

4848
SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
4949

50-
source ${SCRIPTPATH}/traceUtils.sh
51-
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/traceUtils.sh" && exit 1
50+
source ${SCRIPTPATH}/utils.sh
51+
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/utils.sh" && exit 1
5252

5353
export WL_HOME="${WL_HOME:-/u01/oracle/wlserver}"
5454

operator/src/main/resources/scripts/startServer.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
#
1111

1212
SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
13-
source ${SCRIPTPATH}/traceUtils.sh
14-
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/traceUtils.sh" && exitOrLoop
13+
source ${SCRIPTPATH}/utils.sh
14+
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/utils.sh" && exitOrLoop
1515

1616
trace "Starting WebLogic Server '${SERVER_NAME}'."
1717

operator/src/main/resources/scripts/stopServer.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
#
1111

1212
SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
13-
source ${SCRIPTPATH}/traceUtils.sh
14-
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/traceUtils.sh" && exit 1
13+
source ${SCRIPTPATH}/utils.sh
14+
[ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/utils.sh" && exit 1
1515

1616
trace "Stop server ${SERVER_NAME}" &>> /weblogic-operator/stopserver.out
1717

@@ -79,4 +79,4 @@ if [ -f /weblogic-operator/pid ]; then
7979
kill -2 $(</weblogic-operator/pid)
8080
fi
8181

82-
trace "Exit script" &>> /weblogic-operator/stopserver.out
82+
trace "Exit script" &>> /weblogic-operator/stopserver.out

operator/src/main/resources/scripts/traceUtils.py renamed to operator/src/main/resources/scripts/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
# Usage: trace('string')
55
#
6-
# This matches format of bash trace_utils.sh trace, and the operator's log format.
6+
# This matches format of bash utils.sh trace, and the operator's log format.
77
#
88
# Sample output: @[2018-09-28T17:23:55.335 UTC][introspectDomain.py:614] Domain introspection complete.
99
#

operator/src/main/resources/scripts/traceUtils.sh renamed to operator/src/main/resources/scripts/utils.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,15 @@
33

44
#
55
# Purpose:
6-
# Define a trace functions that match format of the trace function
7-
# in traceUtils.py and of the logging in the java operator.
6+
# Define trace functions that match format of the trace function
7+
# in utils.py and of the logging in the java operator.
8+
#
9+
# Define various shared utility functions.
810
#
911
# Load this file via the following pattern:
1012
# SCRIPTPATH="$( cd "$(dirname "$0")" > /dev/null 2>&1 ; pwd -P )"
11-
# source ${SCRIPTPATH}/traceUtils.sh
12-
# [ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/traceUtils.sh" && exit 1
13+
# source ${SCRIPTPATH}/utils.sh
14+
# [ $? -ne 0 ] && echo "Error: missing file ${SCRIPTPATH}/utils.sh" && exit 1
1315
#
1416

1517
# timestamp

0 commit comments

Comments
 (0)