-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
https://github.com/itext/i7j-pdfsweep/releases/tag/2.0.6 * release_branch: [RELEASE] pdfSweep 2.0.6 Add tests for cleanup of skewed images Add test for indexed colorspace without white color Update copyright year to 2021 Update dependencies Update CONTRIBUTING.md with latest information and links Get rid of using "LicenseKeyProductFeature" in ReflectionUtils class in cleanup module Make mutable final sets unmodifable Move reflection code to ReflectionUtils class Add PdfAutoSweep tests and change annotation name generator Update dependencies Pdf test files were changed. Added unit tests for openNotWrittenTags. Make PdfCleanUpFilter class autoportable [RELEASE] Update dependency versions Use generalized Jenkinsfile in pipeline-library Abort possible previous builds Update .mailmap Create new CleanUp comparing approach Add test for Java and.NET differences in line arts drawing on canvas Add missing category to a test [RELEASE] Update dependency versions Performance improvements of Jenkins builds add test case for "fix missing index and newlines in cleanup regexes" in itextcore repository [RELEASE] Update dependency versions Add test for circular references in form xObjects
- Loading branch information
Showing
79 changed files
with
1,960 additions
and
786 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,170 +1,7 @@ | ||
#!/usr/bin/env groovy | ||
@Library('pipeline-library')_ | ||
|
||
def schedule = env.BRANCH_NAME.contains('master') ? '@monthly' : env.BRANCH_NAME == 'develop' ? '@midnight' : '' | ||
def sonarBranchName = env.BRANCH_NAME.contains('master') ? '-Dsonar.branch.name=master' : '-Dsonar.branch.name=' + env.BRANCH_NAME | ||
def sonarBranchTarget = env.BRANCH_NAME.contains('master') ? '' : env.BRANCH_NAME == 'develop' ? '-Dsonar.branch.target=master' : '-Dsonar.branch.target=develop' | ||
def repoName = "pdfSweep" | ||
def dependencyRegex = "itextcore" | ||
|
||
pipeline { | ||
|
||
agent any | ||
|
||
environment { | ||
JDK_VERSION = 'jdk-8-oracle' | ||
} | ||
|
||
options { | ||
ansiColor('xterm') | ||
buildDiscarder(logRotator(artifactNumToKeepStr: '1')) | ||
parallelsAlwaysFailFast() | ||
skipStagesAfterUnstable() | ||
timeout(time: 60, unit: 'MINUTES') | ||
timestamps() | ||
} | ||
|
||
triggers { | ||
cron(schedule) | ||
} | ||
|
||
tools { | ||
maven 'M3' | ||
jdk "${JDK_VERSION}" | ||
} | ||
|
||
stages { | ||
stage('Wait for blocking jobs') { | ||
steps { | ||
script { | ||
properties([[$class: 'BuildBlockerProperty', blockLevel: 'GLOBAL', blockingJobs: ".*/itextcore/${env.JOB_BASE_NAME}", scanQueueFor: 'ALL', useBuildBlocker: true]]) | ||
} | ||
} | ||
} | ||
stage('Build') { | ||
options { | ||
retry(2) | ||
} | ||
stages { | ||
stage('Clean workspace') { | ||
options { | ||
timeout(time: 5, unit: 'MINUTES') | ||
} | ||
steps { | ||
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') { | ||
sh 'mvn clean' | ||
sh 'mvn dependency:purge-local-repository -Dinclude=com.itextpdf -DresolutionFuzziness=groupId -DreResolve=false' | ||
} | ||
} | ||
} | ||
stage('Compile') { | ||
options { | ||
timeout(time: 5, unit: 'MINUTES') | ||
} | ||
steps { | ||
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') { | ||
sh 'mvn compile test-compile package -Dmaven.test.skip=true -Dmaven.javadoc.failOnError=false' | ||
} | ||
} | ||
} | ||
} | ||
post { | ||
failure { | ||
sleep time: 2, unit: 'MINUTES' | ||
} | ||
success { | ||
script { currentBuild.result = 'SUCCESS' } | ||
} | ||
} | ||
} | ||
stage('Run Tests') { | ||
options { | ||
timeout(time: 30, unit: 'MINUTES') | ||
} | ||
steps { | ||
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') { | ||
withSonarQubeEnv('Sonar') { | ||
sh 'mvn --activate-profiles test -DgsExec="${gsExec}" -DcompareExec="${compareExec}" -Dmaven.test.skip=false -Dmaven.test.failure.ignore=false -Dmaven.javadoc.skip=true org.jacoco:jacoco-maven-plugin:prepare-agent verify org.jacoco:jacoco-maven-plugin:report -Dsonar.java.spotbugs.reportPaths="target/spotbugs.xml" sonar:sonar ' + sonarBranchName + ' ' + sonarBranchTarget | ||
} | ||
} | ||
} | ||
} | ||
stage('Static Code Analysis') { | ||
options { | ||
timeout(time: 30, unit: 'MINUTES') | ||
} | ||
steps { | ||
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') { | ||
sh 'mvn --activate-profiles qa verify -Dpmd.analysisCache=true' | ||
} | ||
} | ||
} | ||
stage("Quality Gate") { | ||
steps { | ||
timeout(time: 1, unit: 'HOURS') { | ||
waitForQualityGate abortPipeline: true | ||
} | ||
} | ||
} | ||
stage('Artifactory Deploy') { | ||
options { | ||
timeout(time: 5, unit: 'MINUTES') | ||
} | ||
when { | ||
anyOf { | ||
branch "master" | ||
branch "develop" | ||
} | ||
} | ||
steps { | ||
script { | ||
def server = Artifactory.server('itext-artifactory') | ||
def rtMaven = Artifactory.newMavenBuild() | ||
rtMaven.deployer server: server, releaseRepo: 'releases', snapshotRepo: 'snapshot' | ||
rtMaven.tool = 'M3' | ||
def buildInfo = rtMaven.run pom: 'pom.xml', goals: 'install -Dmaven.test.skip=true -Dspotbugs.skip=true -Dmaven.javadoc.failOnError=false' | ||
server.publishBuildInfo buildInfo | ||
} | ||
} | ||
} | ||
stage('Archive Artifacts') { | ||
options { | ||
timeout(time: 5, unit: 'MINUTES') | ||
} | ||
steps { | ||
archiveArtifacts allowEmptyArchive: true, artifacts: 'target/*.jar, target/*.pom', excludes: '**/fb-contrib-*.jar, **/findsecbugs-plugin-*.jar' | ||
} | ||
} | ||
} | ||
|
||
post { | ||
always { | ||
echo 'One way or another, I have finished \uD83E\uDD16' | ||
} | ||
success { | ||
echo 'I succeeeded! \u263A' | ||
} | ||
unstable { | ||
echo 'I am unstable \uD83D\uDE2E' | ||
} | ||
failure { | ||
echo 'I failed \uD83D\uDCA9' | ||
} | ||
changed { | ||
echo 'Things were different before... \uD83E\uDD14' | ||
} | ||
fixed { | ||
script { | ||
if (env.BRANCH_NAME.contains('master') || (env.BRANCH_NAME == 'develop')) { | ||
slackNotifier("#ci", currentBuild.currentResult, "${env.BRANCH_NAME} - Back to normal") | ||
} | ||
} | ||
} | ||
regression { | ||
script { | ||
if (env.BRANCH_NAME.contains('master') || (env.BRANCH_NAME == 'develop')) { | ||
slackNotifier("#ci", currentBuild.currentResult, "${env.BRANCH_NAME} - First failure") | ||
} | ||
} | ||
} | ||
} | ||
|
||
} | ||
automaticJavaBuild(repoName, dependencyRegex) |
Oops, something went wrong.