Skip to content

Commit b2c1121

Browse files
authored
Jetty 12.0.x publish dependency report (jetty#9504)
* add Jenkins file for dependency report Signed-off-by: Olivier Lamy <[email protected]>
1 parent 89a519b commit b2c1121

File tree

3 files changed

+54
-10
lines changed

3 files changed

+54
-10
lines changed

Jenkinsfile-autobahn

+3-5
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,9 @@ pipeline {
1717
node { label 'linux' }
1818
}
1919
steps {
20-
container( 'jetty-build' ) {
21-
timeout( time: 120, unit: 'MINUTES' ) {
22-
mavenBuild( "jdk11", "-T3 clean install -Djacoco.skip=true -Pautobahn", "maven3", true ) //
23-
junit testResults: '**/target/surefire-reports/*.xml,**/target/invoker-reports/TEST*.xml,**/target/autobahntestsuite-reports/*.xml'
24-
}
20+
timeout( time: 120, unit: 'MINUTES' ) {
21+
mavenBuild( "jdk11", "-T3 clean install -Djacoco.skip=true -Pautobahn", "maven3", true ) //
22+
junit testResults: '**/target/surefire-reports/*.xml,**/target/invoker-reports/TEST*.xml,**/target/autobahntestsuite-reports/*.xml'
2523
}
2624
}
2725
}

Jenkinsfile-dependency-report

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
#!groovy
2+
3+
pipeline {
4+
agent any
5+
triggers {
6+
pollSCM('@weekly')
7+
}
8+
options {
9+
skipDefaultCheckout()
10+
buildDiscarder logRotator( numToKeepStr: '50' )
11+
// save some io during the build
12+
durabilityHint( 'PERFORMANCE_OPTIMIZED' )
13+
}
14+
parameters {
15+
string( defaultValue: 'jetty-12.0.x', description: 'Jetty branch to build',
16+
name: 'JETTY_BRANCH' )
17+
}
18+
stages {
19+
stage( "Build / Dependency Report" ) {
20+
agent {
21+
node { label 'linux' }
22+
}
23+
steps {
24+
timeout( time: 120, unit: 'MINUTES' ) {
25+
withEnv(["JAVA_HOME=${ tool "jdk17" }",
26+
"PATH+MAVEN=${ tool "jdk17" }/bin:${tool "maven3"}/bin",
27+
"MAVEN_OPTS=-Xms2g -Xmx4g -Djava.awt.headless=true"]) {
28+
checkout([$class: 'GitSCM',
29+
branches: [[name: "$JETTY_BRANCH"]],
30+
extensions: [[$class: 'CloneOption', depth: 1, noTags: true, shallow: true, reference: "/home/jenkins/jetty.project.git"]],
31+
userRemoteConfigs: [[url: 'https://github.com/eclipse/jetty.project.git']]])
32+
sh "mvn install -ntp -DskipTests -T5"
33+
sh "bash ./build/scripts/dependency-update-reports.sh"
34+
publishHTML([allowMissing: false, alwaysLinkToLastBuild: true, keepAll: true, reportDir: "reports/dependency-update-reports/", reportFiles: 'dependency-updates-report-*.html', reportName: 'Dependencies Report', reportTitles: ''])
35+
}
36+
}
37+
}
38+
}
39+
}
40+
}
41+
42+
43+
44+
45+
46+
// vim: et:ts=2:sw=2:ft=groovy

build/scripts/dependency-update-reports.sh

+5-5
Original file line numberDiff line numberDiff line change
@@ -14,28 +14,28 @@ mkdir -p $REPORT_OUTPUT_DIR
1414

1515
echo "HTML Reports can be found in $REPORT_OUTPUT_DIR"
1616

17-
mvn -N -Pdependency-updates-reports validate
17+
mvn -N -B -Pdependency-updates-reports validate
1818

1919
cp -Rv target/site/* $REPORT_OUTPUT_DIR
2020
mv $REPORT_OUTPUT_DIR/dependency-updates-aggregate-report.html $REPORT_OUTPUT_DIR/dependency-updates-report-root.html
2121

2222
pushd jetty-core
23-
mvn -Pdependency-updates-reports validate
23+
mvn -B -Pdependency-updates-reports validate
2424
cp target/site/dependency-updates-aggregate-report.html $REPORT_OUTPUT_DIR/dependency-updates-report-core.html
2525
popd
2626

2727
pushd jetty-ee10
28-
mvn -Pdependency-updates-reports validate
28+
mvn -B -Pdependency-updates-reports validate
2929
cp target/site/dependency-updates-aggregate-report.html $REPORT_OUTPUT_DIR/dependency-updates-report-ee10.html
3030
popd
3131

3232
pushd jetty-ee9
33-
mvn -Pdependency-updates-reports validate
33+
mvn -B -Pdependency-updates-reports validate
3434
cp target/site/dependency-updates-aggregate-report.html $REPORT_OUTPUT_DIR/dependency-updates-report-ee9.html
3535
popd
3636

3737
pushd jetty-ee8
38-
mvn -Pdependency-updates-reports validate
38+
mvn -B -Pdependency-updates-reports validate
3939
cp target/site/dependency-updates-aggregate-report.html $REPORT_OUTPUT_DIR/dependency-updates-report-ee8.html
4040
popd
4141

0 commit comments

Comments
 (0)