From 5a89fe6e53e51122e2324599de25754674aba5ef Mon Sep 17 00:00:00 2001 From: Dom G Date: Tue, 15 Sep 2026 11:09:10 -0400 Subject: [PATCH 1/2] Properly exit subshell on error in accumulo-cluster script --- assemble/bin/accumulo-cluster | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/assemble/bin/accumulo-cluster b/assemble/bin/accumulo-cluster index 7e8bd9a00c4..6968c9bc215 100755 --- a/assemble/bin/accumulo-cluster +++ b/assemble/bin/accumulo-cluster @@ -297,7 +297,10 @@ function parse_config() { exit 1 fi - AC_TMP_DIR=$(mktemp -t -d "accumulo-cluster-XXXXXXXX") || (echo "Error creating temp file" && exit 1) + AC_TMP_DIR=$(mktemp -t -d "accumulo-cluster-XXXXXXXX") || { + echo "Error creating temp file" >&2 + exit 1 + } if isDebug; then echo "$(blue DEBUG): Temporary files for this run are in $AC_TMP_DIR" else @@ -306,7 +309,10 @@ function parse_config() { RG_FILE="$AC_TMP_DIR/ZooInfoViewer.out" debug "Printing resource groups to $RG_FILE" - "$accumulo_cmd" zk info-viewer --print-resource-groups >"$RG_FILE" || (echo "Error getting resource groups. Did you init?" && exit 1) + "$accumulo_cmd" zk info-viewer --print-resource-groups >"$RG_FILE" || { + echo "Error getting resource groups. Did you init?" >&2 + exit 1 + } read -r -a all_resource_groups <<<"$(grep -F 'Resource Groups: ' "$RG_FILE" | cut -c18-)" debug "All resource groups: ${all_resource_groups[*]}" @@ -718,7 +724,10 @@ function prune() { exit 1 fi local service_json="$AC_TMP_DIR/accumulo-service.json" - "$accumulo_cmd" inst service-status --json >"$service_json" 2>/dev/null || (echo "Error calling 'inst serviceStatus'" && exit 1) + "$accumulo_cmd" inst service-status --json >"$service_json" 2>/dev/null || { + echo "Error calling 'inst serviceStatus'" >&2 + exit 1 + } local var_name local hosts From 529672708f7cceecc80a0323e3cf54e144e4e253 Mon Sep 17 00:00:00 2001 From: "Dom G." Date: Tue, 15 Sep 2026 11:17:50 -0400 Subject: [PATCH 2/2] existing typo fix --- assemble/bin/accumulo-cluster | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assemble/bin/accumulo-cluster b/assemble/bin/accumulo-cluster index 6968c9bc215..e19bc83ddc9 100755 --- a/assemble/bin/accumulo-cluster +++ b/assemble/bin/accumulo-cluster @@ -725,7 +725,7 @@ function prune() { fi local service_json="$AC_TMP_DIR/accumulo-service.json" "$accumulo_cmd" inst service-status --json >"$service_json" 2>/dev/null || { - echo "Error calling 'inst serviceStatus'" >&2 + echo "Error calling 'inst service-status'" >&2 exit 1 }