Skip to content

Commit 0113dfa

Browse files
committed
ft-orchestration jq.py use jq with --round-robin
1 parent 2646c8a commit 0113dfa

File tree

1 file changed

+6
-2
lines changed
  • tools/ft-orchestration/src/collector

1 file changed

+6
-2
lines changed

tools/ft-orchestration/src/collector/jq.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ def __init__(self, executor: Executor, file: str):
121121
EOF
122122
123123
ipfixcol2 -c {Path(self._conf_dir, self.CONFIG_FILE)} |
124-
parallel --pipe --recend '\n' --line-buffer --memfree 6G -L 200K --retries 0 -j 100% -- jq -r -f "$file"
124+
parallel --pipe --round-robin --recend '\n' --line-buffer -j 100% -- jq -r -f "$file"
125125
"""
126126
# Reads fds file and outputs json with ipfixcol2, then converts json with jq to csv.
127127
# In the csv output the IPv4/IPv6 addresses are merged to source/destinationIPAddress.
@@ -343,7 +343,11 @@ def save_csv(csv_file: str):
343343
with open(csv_file, mode="w") as f:
344344
f.write(",".join(header) + "\n")
345345

346-
Tool(ssh_cmd).run()
346+
cmd = Tool(ssh_cmd)
347+
cmd.run()
348+
349+
if cmd.returncode() > 0:
350+
raise CollectorOutputReaderException(cmd)
347351

348352
end = time.time()
349353
try:

0 commit comments

Comments
 (0)