Skip to content

Commit 69c78e1

Browse files
committed
chore: exclude some unused Jackson artifacts
spring-boot-starter-web had a dependency on spring-boot-starter-json that brought Jackson with other extra dependencies: * jackson-datatype-jdk8 Add-on module for Jackson to support JDK 8 data types * jackson-datatype-jsr310 Add-on module to support JSR-310 (Java 8 Date & Time API) data types * jackson-module-parameter-names Add-on module for Jackson to support introspection of method/constructor parameter names, without having to add explicit property name annotation. At this moment none of them are needed and this change excludes them from resulted WAR file.
1 parent e9eb623 commit 69c78e1

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

pom.xml

+11
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,11 @@
133133
<groupId>org.springframework.boot</groupId>
134134
<artifactId>spring-boot-starter-web</artifactId>
135135
<exclusions>
136+
<exclusion>
137+
<!-- We specify dependency on jackson-databind manually -->
138+
<groupId>org.springframework.boot</groupId>
139+
<artifactId>spring-boot-starter-json</artifactId>
140+
</exclusion>
136141
<exclusion>
137142
<!-- In favour of spring-boot-starter-jetty -->
138143
<groupId>org.springframework.boot</groupId>
@@ -181,6 +186,12 @@
181186
<scope>provided</scope>
182187
</dependency>
183188

189+
<dependency>
190+
<groupId>com.fasterxml.jackson.core</groupId>
191+
<artifactId>jackson-databind</artifactId>
192+
<scope>runtime</scope>
193+
</dependency>
194+
184195
<!-- Dependencies which used only in test environment -->
185196
<dependency>
186197
<groupId>com.h2database</groupId>

0 commit comments

Comments
 (0)