Skip to content

Commit d6a59bc

Browse files
committed
[RELEASE] iText 7 pdfHTML - 2.1.7
https://github.com/itext/i7j-pdfhtml/releases/tag/2.1.7 * release/2.1.7: [RELEASE] 2.1.7-SNAPSHOT -> 2.1.7 Unignore FontFaceTest methods Update ToDo remarks Fix test cmp Add missing copyright headers Add missing copyright headers Implement lang attribute processing Fix cmp files Fix in Jenkinsfile for the workspace Change Jenkinsfile so that the dependencies are used from branch-artifacts repo Change in Jenkinsfile to reset build result when retrying a stage Change Jenkinsfile to retry clearing the workspace and compiling when anything fails Change Jenkinsfile so that the build is blocked when there is an itextcore build running Add Test postfix to the test classes names. Update TODO's comments Update test search wildcard expression so that all the files are picked up Update ConverterProperties JavaDoc Refactor resource tests, add tests on releasing font and css [RELEASE] Update dependency versions Change line width in cmp files Add new test demonstrating a problem of checkboxes not being tagged
2 parents 2f40ee8 + 8e80454 commit d6a59bc

File tree

1,358 files changed

+3601
-1606
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,358 files changed

+3601
-1606
lines changed

Jenkinsfile

Lines changed: 113 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ pipeline {
1717
ansiColor('xterm')
1818
buildDiscarder(logRotator(artifactNumToKeepStr: '1'))
1919
parallelsAlwaysFailFast()
20-
retry(1)
2120
skipStagesAfterUnstable()
2221
timeout(time: 60, unit: 'MINUTES')
2322
timestamps()
@@ -33,24 +32,89 @@ pipeline {
3332
}
3433

3534
stages {
36-
stage('Clean workspace') {
37-
options {
38-
timeout(time: 5, unit: 'MINUTES')
39-
}
35+
stage('Wait for blocking jobs') {
4036
steps {
41-
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') {
42-
sh 'mvn clean'
43-
sh 'mvn dependency:purge-local-repository -Dinclude=com.itextpdf -DresolutionFuzziness=groupId -DreResolve=false'
37+
script {
38+
properties([[$class: 'BuildBlockerProperty', blockLevel: 'GLOBAL', blockingJobs: ".*/itextcore/${env.JOB_BASE_NAME}", scanQueueFor: 'ALL', useBuildBlocker: true]])
4439
}
4540
}
4641
}
47-
stage('Compile') {
42+
stage('Build') {
4843
options {
49-
timeout(time: 5, unit: 'MINUTES')
44+
retry(2)
5045
}
51-
steps {
52-
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') {
53-
sh 'mvn compile test-compile package -Dmaven.test.skip=true -Dmaven.javadoc.failOnError=false'
46+
stages {
47+
stage('Clean workspace') {
48+
options {
49+
timeout(time: 5, unit: 'MINUTES')
50+
}
51+
steps {
52+
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') {
53+
sh 'mvn clean'
54+
sh 'mvn dependency:purge-local-repository -Dinclude=com.itextpdf -DresolutionFuzziness=groupId -DreResolve=false'
55+
}
56+
script {
57+
try {sh "rm -rf ${env.WORKSPACE.replace('\\','/')}/downloads"} catch (Exception err) {}
58+
}
59+
}
60+
}
61+
stage('Install branch dependencies') {
62+
options {
63+
timeout(time: 5, unit: 'MINUTES')
64+
}
65+
when {
66+
not {
67+
anyOf {
68+
branch "master"
69+
branch "develop"
70+
}
71+
}
72+
}
73+
steps {
74+
script {
75+
getAndConfigureJFrogCLI()
76+
sh "./jfrog rt dl branch-artifacts/${env.JOB_BASE_NAME}/**/java/ downloads/"
77+
if(fileExists("downloads")) {
78+
dir ("downloads") {
79+
def mainPomFiles = findFiles(glob: '**/main.pom')
80+
mainPomFiles.each{ pomFile ->
81+
pomPath = pomFile.path.replace("\\","/")
82+
sh "mvn org.apache.maven.plugins:maven-install-plugin:3.0.0-M1:install-file --quiet -Dmaven.repo.local=${env.WORKSPACE.replace('\\','/')}/.repository -Dpackaging=pom -Dfile=${pomPath} -DpomFile=${pomPath}"
83+
}
84+
def pomFiles = findFiles(glob: 'downloads/**/*.pom')
85+
pomFiles.each{ pomFile ->
86+
if (pomFile.name != "main.pom") {
87+
pomPath = pomFile.path.replace("\\","/")
88+
sh "mvn org.apache.maven.plugins:maven-install-plugin:3.0.0-M1:install-file --quiet -Dmaven.repo.local=${env.WORKSPACE.replace('\\','/')}/.repository -Dpackaging=pom -Dfile=${pomPath} -DpomFile=${pomPath}"
89+
}
90+
}
91+
def jarFiles = findFiles(glob: '**/*.jar')
92+
jarFiles.each{ jarFile ->
93+
jarPath = jarFile.path.replace("\\","/")
94+
sh "mvn org.apache.maven.plugins:maven-install-plugin:3.0.0-M1:install-file --quiet -Dmaven.repo.local=${env.WORKSPACE.replace('\\','/')}/.repository -Dfile=${jarPath}"
95+
}
96+
}
97+
}
98+
}
99+
}
100+
}
101+
stage('Compile') {
102+
options {
103+
timeout(time: 5, unit: 'MINUTES')
104+
}
105+
steps {
106+
withMaven(jdk: "${JDK_VERSION}", maven: 'M3', mavenLocalRepo: '.repository') {
107+
sh 'mvn compile test-compile package -Dmaven.test.skip=true -Dmaven.javadoc.failOnError=false'
108+
}
109+
}
110+
}
111+
}
112+
post {
113+
failure {
114+
sleep time: 2, unit: 'MINUTES'
115+
}
116+
success {
117+
script { currentBuild.result = 'SUCCESS' }
54118
}
55119
}
56120
}
@@ -104,6 +168,42 @@ pipeline {
104168
}
105169
}
106170
}
171+
stage('Branch Artifactory Deploy') {
172+
options {
173+
timeout(time: 5, unit: 'MINUTES')
174+
}
175+
when {
176+
not {
177+
anyOf {
178+
branch "master"
179+
branch "develop"
180+
}
181+
}
182+
}
183+
steps {
184+
script {
185+
if (env.GIT_URL) {
186+
repoName = ("${env.GIT_URL}" =~ /(.*\/)(.*)(\.git)/)[ 0 ][ 2 ]
187+
findFiles(glob: 'target/*.jar').each { item ->
188+
if (!(item ==~ /.*\/fb-contrib-.*?.jar/) && !(item ==~ /.*\/findsecbugs-plugin-.*?.jar/) && !(item ==~ /.*-sources.jar/) && !(item ==~ /.*-javadoc.jar/)) {
189+
sh "./jfrog rt u \"${item.path}\" branch-artifacts/${env.BRANCH_NAME}/${repoName}/java/ --recursive=false --build-name ${env.BRANCH_NAME} --build-number ${env.BUILD_NUMBER} --props \"vcs.revision=${env.GIT_COMMIT};repo.name=${repoName}\""
190+
}
191+
}
192+
findFiles(glob: '**/pom.xml').each { item ->
193+
def pomPath = item.path.replace('\\','/')
194+
if (!(pomPath ==~ /.*target.*/)) {
195+
def resPomName = "main.pom"
196+
def subDirMatcher = (pomPath =~ /^.*(?<=\/|^)(.*)\/pom\.xml/)
197+
if (subDirMatcher.matches()) {
198+
resPomName = "${subDirMatcher[ 0 ][ 1 ]}.pom"
199+
}
200+
sh "./jfrog rt u \"${item.path}\" branch-artifacts/${env.BRANCH_NAME}/${repoName}/java/${resPomName} --recursive=false --build-name ${env.BRANCH_NAME} --build-number ${env.BUILD_NUMBER} --props \"vcs.revision=${env.GIT_COMMIT};repo.name=${repoName}\""
201+
}
202+
}
203+
}
204+
}
205+
}
206+
}
107207
stage('Archive Artifacts') {
108208
options {
109209
timeout(time: 5, unit: 'MINUTES')

pom.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
<parent>
55
<groupId>com.itextpdf</groupId>
66
<artifactId>root</artifactId>
7-
<version>7.1.9</version>
7+
<version>7.1.10</version>
88
<relativePath/>
99
</parent>
1010
<artifactId>html2pdf</artifactId>
11-
<version>2.1.6</version>
11+
<version>2.1.7</version>
1212
<name>pdfHTML</name>
1313
<description>pdfHTML is an iText 7 add-on that lets you to parse (X)HTML snippets and the associated CSS and converts
1414
them to PDF.</description>
@@ -100,7 +100,7 @@
100100
<version>${failsafe.version}</version>
101101
<configuration>
102102
<includes>
103-
<include>**/*Test.java</include>
103+
<include>**/*.java</include>
104104
</includes>
105105
<groups>${integrationtests}</groups>
106106
</configuration>

0 commit comments

Comments
 (0)