mirror of https://github.com/apache/cassandra
Timing info for each test split in Jenkinsfile
patch by Mick Semb Wever; reviewed by Brandon Williams for CASSANDRA-20157
This commit is contained in:
parent
4ae1aee39b
commit
3cdd540bfe
|
|
@ -157,6 +157,11 @@ def tasks() {
|
||||||
}
|
}
|
||||||
|
|
||||||
def testSteps = [
|
def testSteps = [
|
||||||
|
// Each splits size need to be high enough to avoid the one hour per split timeout,
|
||||||
|
// and low enough so test time is factors more than the setup+build time in each split.
|
||||||
|
// Splits can also be poorly balanced: splitting or renaming test classes is the best tactic.
|
||||||
|
// On unsaturated systems 10 minutes per split is optimal, higher with saturation
|
||||||
|
// (some buffer on the heaviest split under the 1h max is required, ref `timeout(…)` in `test(…)`)
|
||||||
'cqlsh-test': [splits: 1],
|
'cqlsh-test': [splits: 1],
|
||||||
'fqltool-test': [splits: 1, size: 'small'],
|
'fqltool-test': [splits: 1, size: 'small'],
|
||||||
'test-cdc': [splits: 8],
|
'test-cdc': [splits: 8],
|
||||||
|
|
@ -383,13 +388,20 @@ def test(command, cell) {
|
||||||
}
|
}
|
||||||
script_vars = fetchDTestsSource(command, script_vars)
|
script_vars = fetchDTestsSource(command, script_vars)
|
||||||
timeout(time: 1, unit: 'HOURS') { // best throughput with each cell at ~10 minutes
|
timeout(time: 1, unit: 'HOURS') { // best throughput with each cell at ~10 minutes
|
||||||
buildJVMDTestJars(cell, script_vars, logfile)
|
def timer = System.currentTimeMillis()
|
||||||
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
|
try {
|
||||||
dir("build") {
|
buildJVMDTestJars(cell, script_vars, logfile)
|
||||||
archiveArtifacts artifacts: "${logfile}", fingerprint: 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} )", returnStatus: true
|
||||||
copyToNightlies("${logfile}", "${cell.step}/${cell.arch}/jdk${cell.jdk}/python${cell.python}/cython_${cell.cython}/" + "split_${cell.split}_${splits}".replace("/", "_"))
|
dir("build") {
|
||||||
|
archiveArtifacts artifacts: "${logfile}", fingerprint: true
|
||||||
|
copyToNightlies("${logfile}", "${cell.step}/${cell.arch}/jdk${cell.jdk}/python${cell.python}/cython_${cell.cython}/" + "split_${cell.split}_${splits}".replace("/", "_"))
|
||||||
|
}
|
||||||
|
if (0 != status) { error("Stage ${cell.step}${cell_suffix} failed with exit status ${status}") }
|
||||||
|
} finally {
|
||||||
|
def duration = System.currentTimeMillis() - timer
|
||||||
|
def formattedTime = String.format("%tT.%tL", duration, duration)
|
||||||
|
echo "Time ${cell.step}${cell_suffix}: ${formattedTime}"
|
||||||
}
|
}
|
||||||
if (0 != status) { error("Stage ${cell.step}${cell_suffix} failed with exit status ${status}") }
|
|
||||||
}
|
}
|
||||||
dir("build") {
|
dir("build") {
|
||||||
sh """
|
sh """
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue