dlmarion commented on code in PR #5158:
URL: https://github.com/apache/accumulo/pull/5158#discussion_r1878826203
##########
assemble/bin/accumulo-cluster:
##########
@@ -177,16 +166,20 @@ function control_service() {
# using the value of $host
#
if [[ $# -gt 3 ]]; then
- debugAndRun ACCUMULO_SERVICE_INSTANCE="${ACCUMULO_SERVICE_INSTANCE}"
"${bin}/accumulo-service" "$service" "$control_cmd" "-a" "$host" "${@:4}"
+ debug "ACCUMULO_SERVICE_INSTANCE=\"$ACCUMULO_SERVICE_INSTANCE\"
\"$bin/accumulo-service\" \"$service\" \"$control_cmd\" -a \"$host\"
\"${*:4}\"" ||
+ ACCUMULO_SERVICE_INSTANCE="$ACCUMULO_SERVICE_INSTANCE"
"$bin/accumulo-service" "$service" "$control_cmd" -a "$host" "${@:4}"
else
- debugAndRun ACCUMULO_SERVICE_INSTANCE="${ACCUMULO_SERVICE_INSTANCE}"
"${bin}/accumulo-service" "$service" "$control_cmd" "-a" "$host"
+ debug "ACCUMULO_SERVICE_INSTANCE=\"$ACCUMULO_SERVICE_INSTANCE\"
\"$bin/accumulo-service\" \"$service\" \"$control_cmd\" -a \"$host\"" ||
+ ACCUMULO_SERVICE_INSTANCE="$ACCUMULO_SERVICE_INSTANCE"
"$bin/accumulo-service" "$service" "$control_cmd" -a "$host"
fi
else
if [[ $# -gt 3 ]]; then
EXTRA_ARGS="${*:4}"
- debugAndRun "$SSH" "$host" "bash -c
'ACCUMULO_SERVICE_INSTANCE=${ACCUMULO_SERVICE_INSTANCE} ${bin}/accumulo-service
\"$service\" \"$control_cmd\" \"-a\" \"$host\" $EXTRA_ARGS '"
+ debug "$SSH \"$host\" \"bash -c
'ACCUMULO_SERVICE_INSTANCE=\\\"$ACCUMULO_SERVICE_INSTANCE\\\"
\\\"$bin/accumulo-service\\\" \\\"$service\\\" \\\"$control_cmd\\\" -a
\\\"$host\\\" $EXTRA_ARGS '\"" ||
Review Comment:
@ctubbsii - I don't remember all of this escaping when you and I were
testing this. IIRC when we were testing, there was a line that performed an
`echo` and then the following line that performed the command. I realize that
the `echo` didn't print exactly what was executed, but it seemed better than
all of this escaping.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]