Skip to content

Commit ee328e6

Browse files
authored
Update Spring AI to 2.0.0-M4 (#1316) (#1325)
1 parent 6c78147 commit ee328e6

File tree

3 files changed

+38
-3
lines changed

3 files changed

+38
-3
lines changed

build.gradle

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ allprojects {
5959
JavaCompile compile ->
6060
compile.options.incremental = true // Gradle 3.4
6161
compile.options.encoding = 'UTF-8'
62+
compile.options.compilerArgs << '-parameters' // Preserve method parameter names for Spring AI reflection
6263
}
6364
}
6465

@@ -347,6 +348,14 @@ allprojects {
347348
// Force consistency for dependencies from pipeline and query
348349
force "org.dom4j:dom4j:${dom4jVersion}"
349350

351+
// Force spring-ai components to bring in spring-* versions that match the rest of spring
352+
force "org.springframework:spring-context-support:${springVersion}"
353+
force "org.springframework:spring-messaging:${springVersion}"
354+
force "org.springframework:spring-webflux:${springVersion}"
355+
356+
// spring-ai dependency. Force to mitigate a CVE.
357+
force "io.modelcontextprotocol.sdk:mcp:${modelContextProtocolVersion}"
358+
350359
// Force consistency between pipeline's ActiveMQ and cloud's jClouds dependencies
351360
force "javax.annotation:javax.annotation-api:${javaxAnnotationVersion}"
352361

@@ -362,6 +371,9 @@ allprojects {
362371
// Force latest hadoop-hdfs-client for CVE-2021-37404, CVE-2022-25168, CVE-2022-26612, CVE-2021-25642, CVE-2021-33036, CVE-2023-26031
363372
force "org.apache.hadoop:hadoop-hdfs-client:${hadoopHdfsClientVersion}"
364373

374+
// Spring AI 2.0 brings in Jackson3. Force it to match embedded and mitigate CVEs.
375+
force "tools.jackson.core:jackson-core:${jackson3Version}"
376+
365377
dependencySubstitution {
366378
// Because the client api artifact name is not the same as the directory structure, we use
367379
// Gradle's dependency substitution so the dependency will appear correctly in the pom files that

dependencyCheckSuppression.xml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -255,4 +255,24 @@
255255
<packageUrl regex="true">^pkg:maven/org\.apache\.pdfbox/pdfbox-tools@.*$</packageUrl>
256256
<cve>CVE-2026-23907</cve>
257257
</suppress>
258+
259+
<!--
260+
False-positives
261+
https://github.com/dependency-check/DependencyCheck/issues/8391
262+
https://github.com/dependency-check/DependencyCheck/issues/8392
263+
-->
264+
<suppress>
265+
<notes><![CDATA[
266+
file name: mcp-spring-webmvc-2.0.0-M3.jar
267+
]]></notes>
268+
<packageUrl regex="true">^pkg:maven/org\.springframework\.ai/mcp-spring-webmvc@.*$</packageUrl>
269+
<cpe>cpe:/a:vmware:server</cpe>
270+
</suppress>
271+
<suppress>
272+
<notes><![CDATA[
273+
file name: mcp-spring-webmvc-2.0.0-M3.jar
274+
]]></notes>
275+
<packageUrl regex="true">^pkg:maven/org\.springframework\.ai/mcp-spring-webmvc@.*$</packageUrl>
276+
<cpe>cpe:/a:vmware:vmware_server</cpe>
277+
</suppress>
258278
</suppressions>

gradle.properties

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,9 @@ lombokVersion=1.18.42
252252

253253
luceneVersion=10.3.2
254254

255+
# Spring-AI dependency that's showing a CVE
256+
modelContextProtocolVersion=1.1.1
257+
255258
mssqlJdbcVersion=13.2.1.jre11
256259

257260
objenesisVersion=1.0
@@ -291,10 +294,10 @@ slf4jLog4jApiVersion=2.0.17
291294
snappyJavaVersion=1.1.10.8
292295

293296
# Also, update apacheTomcatVersion above to match Spring Boot's Tomcat dependency version
294-
springBootVersion=4.0.3
297+
springBootVersion=4.0.4
295298
# This usually matches the Spring Framework version dictated by springBootVersion
296-
springVersion=7.0.5
297-
springAiVersion=2.0.0-M2
299+
springVersion=7.0.6
300+
springAiVersion=2.0.0-M4
298301

299302
sqliteJdbcVersion=3.51.1.0
300303

0 commit comments

Comments
 (0)