Skip to content

Commit

Permalink
Add ability to skip cqlsh, and config collection, commands
Browse files Browse the repository at this point in the history
Using noCqlsh and skipConfig environment variables
Also fix cassandraNodes variable when using collector.hosts
  • Loading branch information
michaelsembwever committed Sep 16, 2024
1 parent e5823a8 commit 15579e3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions ds-collector/ds-collector
Original file line number Diff line number Diff line change
Expand Up @@ -1013,6 +1013,7 @@ get_infos() {
while read -u10 hostName; do
if [[ "$hostName" != \#* ]] && [ "$hostName" ]; then
get_info
cassandraNodes="${cassandraNodes} ${hostName}"
fi
done 10< $hostFile
elif [[ ${runOnSingleNode} != "true" ]] && [[ "$hostName" != \#* ]] && [ "$hostName" ]; then
Expand Down
6 changes: 3 additions & 3 deletions ds-collector/rust-commands/collect-info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ const COMMANDS: &[Cmd<'static>] = &[
args: "{cqlsh_host} {cqlsh_port} {cqlsh_opts} -f {artifact_dir}/execute_schema.cql",
file: "schema.cql",
optional: false,
skip_flags: "",
skip_flags: "noCqlsh",
use_stdout: true,
use_sudo: false,
use_timeout: false,
Expand All @@ -348,7 +348,7 @@ const COMMANDS: &[Cmd<'static>] = &[
args: "{cqlsh_host} {cqlsh_port} {cqlsh_opts} -f {artifact_dir}/execute_metadata.cql",
file: "driver/metadata.txt",
optional: true,
skip_flags: "",
skip_flags: "noCqlsh",
use_stdout: true,
use_sudo: false,
use_timeout: false,
Expand Down Expand Up @@ -778,7 +778,7 @@ const COMMANDS: &[Cmd<'static>] = &[
args: "{config_home} {artifact_dir}/conf",
file: "",
optional: false,
skip_flags: "",
skip_flags: "skipConfig",
use_stdout: true,
use_sudo: false,
use_timeout: false,
Expand Down

0 comments on commit 15579e3

Please sign in to comment.