Skip to content

Commit 4a70abf

Browse files
committed
[1401] Use GeoTools Bill of Materials (BOM) to manage geotools dependency versions
This commit integrates the GeoTools Bill of Materials (gt-bom) into GeoWebCache, centralizing management of GeoTools dependency versions. * Import `org.geotools:gt-bom` in the root `pom.xml`'s `<dependencyManagement>` section. This makes GeoWebCache a direct consumer of GeoTools' curated dependency set. * Remove explicit `<version>${gt.version}</version>` declarations for individual GeoTools artifacts from all module POMs. Versions are now inherited from the imported `gt-bom`. * Remove unused dependency org.freemarker:freemarker * Delegate the following dependency versions to the GeoTools BOM: * apache commons (io, logging, collections, text, dbcp) * guava * h2 * hsqldb * httpclient * imageio-ext * jackson-annotations * jackson-core * jackson-databind * jai_core/codec * jai_imageio * jaiext * jts * log4j-1.2-api * log4j-api * log4j-core * log4j-jcl * log4j-jul * log4j-slf4j2-impl * ojdbc14 * postgresql * slf4j-api
1 parent 3b95025 commit 4a70abf

9 files changed

Lines changed: 22 additions & 213 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
*.settings
33
*.project
44
.factorypath
5+
.pmd
56
bin
67
target
78
.DS_Store

geowebcache/core/pom.xml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
<dependency>
1919
<groupId>org.geotools</groupId>
2020
<artifactId>gt-metadata</artifactId>
21-
<version>${gt.version}</version>
2221
</dependency>
2322
<dependency>
2423
<groupId>org.apache.commons</groupId>
@@ -125,19 +124,16 @@
125124
<dependency>
126125
<groupId>javax.media</groupId>
127126
<artifactId>jai_core</artifactId>
128-
<version>1.1.3</version>
129127
</dependency>
130128

131129
<dependency>
132130
<groupId>javax.media</groupId>
133131
<artifactId>jai_codec</artifactId>
134-
<version>1.1.3</version>
135132
</dependency>
136133

137134
<dependency>
138135
<groupId>javax.media</groupId>
139136
<artifactId>jai_imageio</artifactId>
140-
<version>1.1</version>
141137
</dependency>
142138

143139
<dependency>

geowebcache/distributed/pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
<dependency>
3333
<groupId>org.geotools</groupId>
3434
<artifactId>gt-xml</artifactId>
35-
<version>${gt.version}</version>
3635
</dependency>
3736
<dependency>
3837
<groupId>junit</groupId>

geowebcache/georss/pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
<dependency>
3030
<groupId>org.geotools</groupId>
3131
<artifactId>gt-coverage</artifactId>
32-
<version>${gt.version}</version>
3332
</dependency>
3433

3534
<!-- test dependencies -->

geowebcache/mbtiles/pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
<dependency>
3030
<groupId>org.geotools</groupId>
3131
<artifactId>gt-mbtiles</artifactId>
32-
<version>${gt.version}</version>
3332
</dependency>
3433

3534
<!-- test dependencies -->

geowebcache/pom.xml

Lines changed: 21 additions & 199 deletions
Original file line numberDiff line numberDiff line change
@@ -52,39 +52,24 @@
5252

5353
<properties>
5454
<gt.version>34-SNAPSHOT</gt.version>
55-
<jts.version>1.20.0</jts.version>
56-
<jaiext.version>1.1.31</jaiext.version>
5755
<spring.version>5.3.39</spring.version>
5856
<spring.security.version>5.7.13</spring.security.version>
5957
<xstream.version>1.4.21</xstream.version>
60-
<commons-io.version>2.18.0</commons-io.version>
61-
<commons-dbcp.version>1.4</commons-dbcp.version>
62-
<commons-collections.version>4.4</commons-collections.version>
6358
<commons-codec.version>1.18.0</commons-codec.version>
64-
<commons-text.version>1.13.0</commons-text.version>
6559
<commons-fileupload.version>1.5</commons-fileupload.version>
66-
<guava.version>33.4.0-jre</guava.version>
6760
<hamcrest.version>3.0</hamcrest.version>
6861
<jsr305.version>3.0.1</jsr305.version>
69-
<log4j.version>2.24.3</log4j.version>
70-
<h2.version>1.1.119</h2.version>
71-
<hsql.version>2.7.1</hsql.version>
72-
<postgresql.version>42.7.5</postgresql.version>
73-
<oracle.version></oracle.version>
7462
<java.awt.headless>true</java.awt.headless>
7563
<jalopy.phase>disabled</jalopy.phase>
7664
<jalopy.srcExcludesPattern>disabled</jalopy.srcExcludesPattern>
7765
<test.maxHeapSize>64M</test.maxHeapSize>
7866
<maven.test.jvmargs></maven.test.jvmargs>
79-
<imageio-ext.version>1.4.15</imageio-ext.version>
8067
<hazelcast.version>5.3.8</hazelcast.version>
8168
<joda-time.version>2.8.1</joda-time.version>
8269
<spotless.action>apply</spotless.action>
8370
<spotless.apply.skip>false</spotless.apply.skip>
8471
<pom.fmt.action>sort</pom.fmt.action>
8572
<pom.fmt.skip>${spotless.apply.skip}</pom.fmt.skip>
86-
<jackson.version>2.18.2</jackson.version>
87-
<jackson.databind.version>${jackson.version}</jackson.databind.version>
8873
<jetty.version>9.4.55.v20240627</jetty.version>
8974
<errorProneFlags></errorProneFlags>
9075
<errorProne.version>2.24.1</errorProne.version>
@@ -102,6 +87,26 @@
10287

10388
<dependencyManagement>
10489
<dependencies>
90+
<!--
91+
Import the GeoTools platform-dependencies BOM to get consistent third-party dependency versions
92+
Provides managed versions for several libraries across projects, such as jackson, commons-logging/pool/lang3/cli/text/dbcp,
93+
JTS, guava, imageio-ext, jai-ext, and more.
94+
-->
95+
<dependency>
96+
<groupId>org.geotools</groupId>
97+
<artifactId>gt-platform-dependencies</artifactId>
98+
<version>${gt.version}</version>
99+
<type>pom</type>
100+
<scope>import</scope>
101+
</dependency>
102+
<!-- Import the GeoTools BOM to have access to all gt artifacts without specifying the version -->
103+
<dependency>
104+
<groupId>org.geotools</groupId>
105+
<artifactId>gt-bom</artifactId>
106+
<version>${gt.version}</version>
107+
<type>pom</type>
108+
<scope>import</scope>
109+
</dependency>
105110
<dependency>
106111
<groupId>org.geowebcache</groupId>
107112
<artifactId>gwc-core</artifactId>
@@ -118,55 +123,18 @@
118123
<scope>import</scope>
119124
</dependency>
120125

121-
<dependency>
122-
<groupId>org.locationtech.jts</groupId>
123-
<artifactId>jts-core</artifactId>
124-
<version>${jts.version}</version>
125-
<exclusions>
126-
<exclusion>
127-
<artifactId>xercesImpl</artifactId>
128-
<groupId>xerces</groupId>
129-
</exclusion>
130-
</exclusions>
131-
</dependency>
132-
133126
<dependency>
134127
<groupId>javax.servlet</groupId>
135128
<artifactId>javax.servlet-api</artifactId>
136129
<version>3.1.0</version>
137130
<scope>provided</scope>
138131
</dependency>
139132

140-
<dependency>
141-
<groupId>com.google.guava</groupId>
142-
<artifactId>guava</artifactId>
143-
<version>${guava.version}</version>
144-
</dependency>
145133
<dependency>
146134
<groupId>com.google.code.findbugs</groupId>
147135
<artifactId>jsr305</artifactId>
148136
<version>${jsr305.version}</version>
149137
</dependency>
150-
<dependency>
151-
<groupId>commons-dbcp</groupId>
152-
<artifactId>commons-dbcp</artifactId>
153-
<version>${commons-dbcp.version}</version>
154-
</dependency>
155-
<dependency>
156-
<groupId>commons-io</groupId>
157-
<artifactId>commons-io</artifactId>
158-
<version>${commons-io.version}</version>
159-
</dependency>
160-
<dependency>
161-
<groupId>org.apache.commons</groupId>
162-
<artifactId>commons-text</artifactId>
163-
<version>${commons-text.version}</version>
164-
</dependency>
165-
<dependency>
166-
<groupId>org.apache.commons</groupId>
167-
<artifactId>commons-collections4</artifactId>
168-
<version>${commons-collections.version}</version>
169-
</dependency>
170138
<dependency>
171139
<groupId>commons-codec</groupId>
172140
<artifactId>commons-codec</artifactId>
@@ -177,106 +145,6 @@
177145
<artifactId>commons-fileupload</artifactId>
178146
<version>${commons-fileupload.version}</version>
179147
</dependency>
180-
<dependency>
181-
<groupId>org.apache.httpcomponents</groupId>
182-
<artifactId>httpclient</artifactId>
183-
<version>4.5.14</version>
184-
</dependency>
185-
186-
<!-- configure geotools logging -->
187-
<dependency>
188-
<groupId>org.geotools</groupId>
189-
<artifactId>gt-metadata</artifactId>
190-
<version>${gt.version}</version>
191-
</dependency>
192-
<!-- logging dependencies -->
193-
<dependency>
194-
<groupId>org.apache.logging.log4j</groupId>
195-
<artifactId>log4j-api</artifactId>
196-
<version>${log4j.version}</version>
197-
</dependency>
198-
<dependency>
199-
<groupId>org.apache.logging.log4j</groupId>
200-
<artifactId>log4j-core</artifactId>
201-
<version>${log4j.version}</version>
202-
</dependency>
203-
<dependency>
204-
<groupId>org.apache.logging.log4j</groupId>
205-
<artifactId>log4j-1.2-api</artifactId>
206-
<version>${log4j.version}</version>
207-
</dependency>
208-
<dependency>
209-
<groupId>org.apache.logging.log4j</groupId>
210-
<artifactId>log4j-jul</artifactId>
211-
<version>${log4j.version}</version>
212-
</dependency>
213-
<!-- bridge slf4j to log4j -->
214-
<dependency>
215-
<groupId>org.apache.logging.log4j</groupId>
216-
<artifactId>log4j-slf4j2-impl</artifactId>
217-
<version>${log4j.version}</version>
218-
</dependency>
219-
<dependency>
220-
<groupId>org.slf4j</groupId>
221-
<artifactId>slf4j-api</artifactId>
222-
<version>2.0.16</version>
223-
</dependency>
224-
225-
<!-- bridge commons-logging to log4j -->
226-
<dependency>
227-
<groupId>org.apache.logging.log4j</groupId>
228-
<artifactId>log4j-jcl</artifactId>
229-
<version>${log4j.version}</version>
230-
</dependency>
231-
<dependency>
232-
<groupId>commons-logging</groupId>
233-
<artifactId>commons-logging</artifactId>
234-
<version>1.3.5</version>
235-
</dependency>
236-
237-
<dependency>
238-
<groupId>it.geosolutions.jaiext.utilities</groupId>
239-
<artifactId>jt-utilities</artifactId>
240-
<version>${jaiext.version}</version>
241-
</dependency>
242-
<dependency>
243-
<groupId>it.geosolutions.jaiext.colorindexer</groupId>
244-
<artifactId>jt-colorindexer</artifactId>
245-
<version>${jaiext.version}</version>
246-
</dependency>
247-
248-
<!-- PNG Encoder dependencies -->
249-
<dependency>
250-
<groupId>it.geosolutions.imageio-ext</groupId>
251-
<artifactId>imageio-ext-png</artifactId>
252-
<version>${imageio-ext.version}</version>
253-
</dependency>
254-
255-
<dependency>
256-
<groupId>it.geosolutions.imageio-ext</groupId>
257-
<artifactId>imageio-ext-streams</artifactId>
258-
<version>${imageio-ext.version}</version>
259-
</dependency>
260-
261-
<!-- dependency>
262-
<groupId>jcs</groupId>
263-
<artifactId>jcs</artifactId>
264-
<version>1.3</version>
265-
<exclusions>
266-
<exclusion>
267-
<groupId>mysql</groupId>
268-
<artifactId>mysql-connector-java</artifactId>
269-
</exclusion>
270-
<exclusion>
271-
<groupId>berkeleydb</groupId>
272-
<artifactId>berkeleydb</artifactId>
273-
</exclusion>
274-
<exclusion>
275-
<groupId>hsqldb</groupId>
276-
<artifactId>hsqldb</artifactId>
277-
</exclusion>
278-
</exclusions>
279-
</dependency -->
280148

281149
<dependency>
282150
<groupId>junit</groupId>
@@ -408,13 +276,6 @@
408276
<scope>test</scope>
409277
</dependency>
410278

411-
<dependency>
412-
<groupId>org.freemarker</groupId>
413-
<artifactId>freemarker</artifactId>
414-
<version>2.3.18</version>
415-
<!-- track same version than GeoServer -->
416-
</dependency>
417-
418279
<dependency>
419280
<groupId>com.thoughtworks.xstream</groupId>
420281
<artifactId>xstream</artifactId>
@@ -438,30 +299,6 @@
438299
<version>1.5.4</version>
439300
</dependency>
440301

441-
<dependency>
442-
<groupId>com.h2database</groupId>
443-
<artifactId>h2</artifactId>
444-
<version>${h2.version}</version>
445-
</dependency>
446-
447-
<dependency>
448-
<groupId>org.hsqldb</groupId>
449-
<artifactId>hsqldb</artifactId>
450-
<version>${hsql.version}</version>
451-
</dependency>
452-
453-
<dependency>
454-
<groupId>org.postgresql</groupId>
455-
<artifactId>postgresql</artifactId>
456-
<version>${postgresql.version}</version>
457-
</dependency>
458-
459-
<dependency>
460-
<groupId>com.oracle</groupId>
461-
<artifactId>ojdbc14</artifactId>
462-
<version>${oracle.version}</version>
463-
</dependency>
464-
465302
<!-- Berkeley DB JE -->
466303
<dependency>
467304
<groupId>com.sleepycat</groupId>
@@ -477,22 +314,7 @@
477314
<version>${joda-time.version}</version>
478315
</dependency>
479316

480-
<!-- Pin some additional transitive dependencies in S3 module for consistency-->
481-
<dependency>
482-
<groupId>com.fasterxml.jackson.core</groupId>
483-
<artifactId>jackson-databind</artifactId>
484-
<version>${jackson.databind.version}</version>
485-
</dependency>
486-
<dependency>
487-
<groupId>com.fasterxml.jackson.core</groupId>
488-
<artifactId>jackson-annotations</artifactId>
489-
<version>${jackson.version}</version>
490-
</dependency>
491-
<dependency>
492-
<groupId>com.fasterxml.jackson.core</groupId>
493-
<artifactId>jackson-core</artifactId>
494-
<version>${jackson.version}</version>
495-
</dependency>
317+
<!-- Jackson dependencies managed by platform-dependencies BOM -->
496318
<dependency>
497319
<!-- used for tests that require environment variables -->
498320
<groupId>com.github.stefanbirkner</groupId>

geowebcache/rest/pom.xml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,6 @@
2525
<artifactId>javax.servlet-api</artifactId>
2626
<scope>provided</scope>
2727
</dependency>
28-
<dependency>
29-
<groupId>org.freemarker</groupId>
30-
<artifactId>freemarker</artifactId>
31-
</dependency>
3228
<dependency>
3329
<groupId>com.google.guava</groupId>
3430
<artifactId>guava</artifactId>

geowebcache/sqlite/pom.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,10 @@
2424
<dependency>
2525
<groupId>org.geotools</groupId>
2626
<artifactId>gt-mbtiles</artifactId>
27-
<version>${gt.version}</version>
2827
</dependency>
2928
<dependency>
3029
<groupId>org.geotools</groupId>
3130
<artifactId>gt-mbtiles</artifactId>
32-
<version>${gt.version}</version>
3331
<classifier>tests</classifier>
3432
<scope>test</scope>
3533
</dependency>

geowebcache/wms/pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
<dependency>
2929
<groupId>org.geotools</groupId>
3030
<artifactId>gt-wms</artifactId>
31-
<version>${gt.version}</version>
3231
</dependency>
3332

3433
<dependency>

0 commit comments

Comments
 (0)