From a5e4c1b149567e5975d4f6d2b215e544339fa572 Mon Sep 17 00:00:00 2001 From: Brandon Williams Date: Thu, 27 Aug 2026 09:35:30 -0500 Subject: [PATCH 1/2] CASSANDRA-21624: Reduce CI console logging * dtest: pytest --log-cli-level=DEBUG dropped to WARNING * Jenkinsfile: filter ant "Forking using command" classpath echoes --- .build/run-python-dtests.sh | 4 +++- .jenkins/Jenkinsfile | 6 +++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.build/run-python-dtests.sh b/.build/run-python-dtests.sh index 8af989d7b4d6..f76d60f9048d 100755 --- a/.build/run-python-dtests.sh +++ b/.build/run-python-dtests.sh @@ -196,7 +196,9 @@ fi SPLIT_TESTS="${SPLIT_TESTS//$'\n'/ }" pytest_results_file="${DIST_DIR}/test/output/nosetests.xml" -pytest_opts="-vv --log-cli-level=DEBUG --junit-xml=${pytest_results_file} --junit-prefix=${DTEST_TARGET} -s" +# WARNING (not DEBUG): the driver's reconnect loop logs full tracebacks at DEBUG, which +# floods the Jenkins console (tens of MB per cell) and the controller's in-memory step log +pytest_opts="-vv --log-cli-level=WARNING --junit-xml=${pytest_results_file} --junit-prefix=${DTEST_TARGET} -s" echo "" echo "pytest ${pytest_opts} --cassandra-dir=${CASSANDRA_DIR} --keep-failed-test-dir ${DTEST_ARGS} ${SPLIT_TESTS}" diff --git a/.jenkins/Jenkinsfile b/.jenkins/Jenkinsfile index 2f0d786ca6ba..0c3803c98858 100644 --- a/.jenkins/Jenkinsfile +++ b/.jenkins/Jenkinsfile @@ -363,7 +363,7 @@ def build(command, cell) { script_vars = "${script_vars} m2_dir=\'${WORKSPACE}/build/m2\'" timeout(time: 1, unit: 'HOURS') { try { - def status = sh label: "RUNNING ${cell.step}...", script: "${script_vars} ${build_script} ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} )", returnStatus: true + def status = sh label: "RUNNING ${cell.step}...", script: "${script_vars} ${build_script} ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} ) | sed -e '/Forking using command/d'", returnStatus: true dir("build") { archiveArtifacts artifacts: "${logfile}", fingerprint: true copyToNightlies("${logfile}", "${cell.step}/jdk${cell.jdk}/${cell.arch}/") @@ -428,7 +428,7 @@ def test(command, cell) { try { buildJVMDTestJars(cell, script_vars, logfile) script_vars = "${script_vars} docker_timeout_hours=\"${command.timeout_hours}\"" - def status = sh label: "RUNNING TESTS ${cell.step}...", script: "${script_vars} .build/docker/run-tests.sh -a ${cell.step} -c '${cell.split}/${splits}' -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} )", returnStatus: true + def status = sh label: "RUNNING TESTS ${cell.step}...", script: "${script_vars} .build/docker/run-tests.sh -a ${cell.step} -c '${cell.split}/${splits}' -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} ) | sed -e '/Forking using command/d'", returnStatus: true dir("build") { archiveArtifacts artifacts: "${logfile}", fingerprint: true } @@ -495,7 +495,7 @@ def buildJVMDTestJars(cell, script_vars, logfile) { try { unstash name: "jvm_dtests_${cell.arch}_${cell.jdk}" } catch (error) { - sh label: "RUNNING build_dtest_jars...", script: "${script_vars} .build/docker/run-tests.sh -a build_dtest_jars -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} )" + sh label: "RUNNING build_dtest_jars...", script: "${script_vars} .build/docker/run-tests.sh -a build_dtest_jars -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} ) | sed -e '/Forking using command/d'" stash name: "jvm_dtests_${cell.arch}_${cell.jdk}", includes: '**/dtest*.jar' } } From f9a14abb9c3ca57e0b9add51c4bf4be287a09dc2 Mon Sep 17 00:00:00 2001 From: Brandon Williams Date: Thu, 3 Sep 2026 22:02:38 +0000 Subject: [PATCH 2/2] CASSANDRA-21624: address review - shared console filter list, INFO log level --- .build/run-python-dtests.sh | 4 ++-- .jenkins/Jenkinsfile | 22 +++++++++++++++++++--- 2 files changed, 21 insertions(+), 5 deletions(-) diff --git a/.build/run-python-dtests.sh b/.build/run-python-dtests.sh index f76d60f9048d..642d7a795ba6 100755 --- a/.build/run-python-dtests.sh +++ b/.build/run-python-dtests.sh @@ -196,9 +196,9 @@ fi SPLIT_TESTS="${SPLIT_TESTS//$'\n'/ }" pytest_results_file="${DIST_DIR}/test/output/nosetests.xml" -# WARNING (not DEBUG): the driver's reconnect loop logs full tracebacks at DEBUG, which +# INFO (not DEBUG): the driver's reconnect loop logs full tracebacks at DEBUG, which # floods the Jenkins console (tens of MB per cell) and the controller's in-memory step log -pytest_opts="-vv --log-cli-level=WARNING --junit-xml=${pytest_results_file} --junit-prefix=${DTEST_TARGET} -s" +pytest_opts="-vv --log-cli-level=INFO --junit-xml=${pytest_results_file} --junit-prefix=${DTEST_TARGET} -s" echo "" echo "pytest ${pytest_opts} --cassandra-dir=${CASSANDRA_DIR} --keep-failed-test-dir ${DTEST_ARGS} ${SPLIT_TESTS}" diff --git a/.jenkins/Jenkinsfile b/.jenkins/Jenkinsfile index 0c3803c98858..9abe469ad1fd 100644 --- a/.jenkins/Jenkinsfile +++ b/.jenkins/Jenkinsfile @@ -336,6 +336,22 @@ def isJdkEnabled(jdk) { return !params.jdk?.trim() || params.jdk.trim() == jdk } +/** + * Noisy (but harmless) output lines, filtered from the in-memory console log. + * The full output is still saved in the archived stage log (build/*.log.xz), + * so this only trims what the controller holds in memory / renders in the UI. + **/ +def consoleNoiseFilters() { + return [ + "Forking using command" // ant echoes the full forked classpath before every maven forked run + ] +} + +// append a sed filter that drops lines matching consoleNoiseFilters() from a step's output +def filterConsoleOutput(String script) { + return "${script} | sed -e " + consoleNoiseFilters().collect { "/${it}/d" }.join(" -e ") +} + /** * Renders build script into pipeline steps **/ @@ -363,7 +379,7 @@ def build(command, cell) { script_vars = "${script_vars} m2_dir=\'${WORKSPACE}/build/m2\'" timeout(time: 1, unit: 'HOURS') { try { - def status = sh label: "RUNNING ${cell.step}...", script: "${script_vars} ${build_script} ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} ) | sed -e '/Forking using command/d'", returnStatus: true + def status = sh label: "RUNNING ${cell.step}...", script: filterConsoleOutput("${script_vars} ${build_script} ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} )"), returnStatus: true dir("build") { archiveArtifacts artifacts: "${logfile}", fingerprint: true copyToNightlies("${logfile}", "${cell.step}/jdk${cell.jdk}/${cell.arch}/") @@ -428,7 +444,7 @@ def test(command, cell) { try { buildJVMDTestJars(cell, script_vars, logfile) script_vars = "${script_vars} docker_timeout_hours=\"${command.timeout_hours}\"" - def status = sh label: "RUNNING TESTS ${cell.step}...", script: "${script_vars} .build/docker/run-tests.sh -a ${cell.step} -c '${cell.split}/${splits}' -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} ) | sed -e '/Forking using command/d'", returnStatus: true + def status = sh label: "RUNNING TESTS ${cell.step}...", script: filterConsoleOutput("${script_vars} .build/docker/run-tests.sh -a ${cell.step} -c '${cell.split}/${splits}' -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} )"), returnStatus: true dir("build") { archiveArtifacts artifacts: "${logfile}", fingerprint: true } @@ -495,7 +511,7 @@ def buildJVMDTestJars(cell, script_vars, logfile) { try { unstash name: "jvm_dtests_${cell.arch}_${cell.jdk}" } catch (error) { - sh label: "RUNNING build_dtest_jars...", script: "${script_vars} .build/docker/run-tests.sh -a build_dtest_jars -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} ) | sed -e '/Forking using command/d'" + sh label: "RUNNING build_dtest_jars...", script: filterConsoleOutput("${script_vars} .build/docker/run-tests.sh -a build_dtest_jars -j ${cell.jdk} 2>&1 | tee >( xz -c > build/${logfile} )") stash name: "jvm_dtests_${cell.arch}_${cell.jdk}", includes: '**/dtest*.jar' } }