Skip to content

Commit 9c362e2

Browse files
committed
Run package phase for faster Artifactory deploy
Also run non-test phases of the Maven lifecycle multithreaded. QA-7892
1 parent 9373d7a commit 9c362e2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Jenkinsfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ pipeline {
3939
}
4040
steps {
4141
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') {
42-
sh 'mvn clean'
42+
sh 'mvn --threads 2C clean'
4343
sh 'mvn dependency:purge-local-repository -Dinclude=com.itextpdf -DresolutionFuzziness=groupId -DreResolve=false'
4444
}
4545
}
@@ -50,7 +50,7 @@ pipeline {
5050
}
5151
steps {
5252
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') {
53-
sh 'mvn compile test-compile package -Dmaven.test.skip=true -Dmaven.javadoc.failOnError=false'
53+
sh 'mvn --threads 2C compile test-compile package -Dmaven.test.skip=true -Dmaven.javadoc.failOnError=false'
5454
}
5555
}
5656
}
@@ -99,7 +99,7 @@ pipeline {
9999
def rtMaven = Artifactory.newMavenBuild()
100100
rtMaven.deployer server: server, releaseRepo: 'releases', snapshotRepo: 'snapshot'
101101
rtMaven.tool = 'M3'
102-
def buildInfo = rtMaven.run pom: 'pom.xml', goals: 'install -Dmaven.test.skip=true -Dspotbugs.skip=true -Dmaven.javadoc.failOnError=false'
102+
def buildInfo = rtMaven.run pom: 'pom.xml', goals: 'package --threads 2C --offline -Dmaven.main.skip=true -Dmaven.test.skip=true -Dmaven.javadoc.failOnError=false'
103103
server.publishBuildInfo buildInfo
104104
}
105105
}

0 commit comments

Comments
 (0)