diag(quic-interop): inspect-testcase pulls [writer.app]/[batch]/[boot]/[interop] traces
Previously the script only showed server stderr — but the bug
investigation needs the CLIENT's runtime traces, which are in the
runner's tee'd stdout (${RUN_DIR}.stdout.log).
awk-narrows the lines to the segment between this testcase's
'Running test case: X' marker and the next one (each testcase runs
a fresh container, so the trace lines between markers are exactly
this testcase's run). Then dumps:
- first 50 [boot] / [interop] / [batch] / [writer.app] lines
- stream_frames=N histogram for the testcase
Useful when debugging a specific testcase failure that requires
seeing the writer's per-drain decisions.
This commit is contained in:
@@ -47,6 +47,31 @@ else
|
||||
echo "(no .stdout.log — run-matrix.sh predates the tee, status not saved)"
|
||||
fi
|
||||
|
||||
echo
|
||||
echo "=============== client diagnostic traces (DEBUG=1) ==============="
|
||||
# All [boot] / [interop] / [batch] / [writer.app] lines from the
|
||||
# runner's tee'd stdout, narrowed to the timeframe of THIS testcase.
|
||||
# The testcase's container restarts between tests so the lines
|
||||
# between two 'Running test case:' markers are this run's.
|
||||
if [[ -f "${RUN_DIR}.stdout.log" ]]; then
|
||||
awk -v tc="$TC" '
|
||||
$0 ~ "Running test case: " tc { in_tc = 1; next }
|
||||
in_tc && /Running test case:/ { exit }
|
||||
in_tc && /\[(boot|interop|batch|writer\.)/ { print }
|
||||
' "${RUN_DIR}.stdout.log" | head -n 50 || true
|
||||
echo "..."
|
||||
echo "stream_frames histogram (this testcase only):"
|
||||
awk -v tc="$TC" '
|
||||
$0 ~ "Running test case: " tc { in_tc = 1; next }
|
||||
in_tc && /Running test case:/ { exit }
|
||||
in_tc { print }
|
||||
' "${RUN_DIR}.stdout.log" \
|
||||
| grep -oE 'stream_frames=[0-9]+' \
|
||||
| sort | uniq -c | sort -rn || echo "(no stream_frames reports)"
|
||||
else
|
||||
echo "(no .stdout.log — re-run with DEBUG=1)"
|
||||
fi
|
||||
|
||||
echo
|
||||
echo "=============== file sizes generated for this testcase ==============="
|
||||
if [[ -f "${RUN_DIR}.stdout.log" ]]; then
|
||||
|
||||
Reference in New Issue
Block a user