Skip to content

Commit d8db58b

Browse files
committed
Upgrade to Spring Boot 4.0.0
Signed-off-by: Sébastien Deleuze <[email protected]>
1 parent 123b36a commit d8db58b

File tree

13 files changed

+47
-29
lines changed

13 files changed

+47
-29
lines changed

README.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ include::https://raw.githubusercontent.com/spring-guides/getting-started-macros/
2020
[[scratch]]
2121
== Starting with Spring Initializr
2222

23-
You can use this https://start.spring.io/#!type=maven-project&packaging=jar&jvmVersion=17&groupId=com.example&artifactId=relational-data-access&name=relational-data-access&description=Demo%20project%20for%20Spring%20Boot&packageName=com.example.relationaldataaccess&dependencies=jdbc,h2[pre-initialized project] and click Generate to download a ZIP file. This project is configured to fit the examples in this tutorial.
23+
You can use this https://start.spring.io/#!type=gradle-project&language=java&jvmVersion=17&packaging=jar&groupId=com.example&artifactId=relational-data-access&packageName=com.example.relationaldataaccess&dependencies=jdbc,h2[pre-initialized project] and click Generate to download a ZIP file. This project is configured to fit the examples in this tutorial.
2424

2525
To manually initialize the project:
2626

complete-kotlin/build.gradle.kts

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
11
plugins {
2-
id("org.springframework.boot") version "3.5.7"
2+
id("org.springframework.boot") version "4.0.0"
33
id("io.spring.dependency-management") version "1.1.7"
4-
kotlin("jvm") version "1.9.25"
5-
kotlin("plugin.spring") version "1.9.25"
4+
kotlin("jvm") version "2.2.21"
5+
kotlin("plugin.spring") version "2.2.21"
66
}
77

88
group = "com.example"
99
version = "0.0.1-SNAPSHOT"
10-
java.sourceCompatibility = JavaVersion.VERSION_17
10+
11+
java {
12+
toolchain {
13+
languageVersion = JavaLanguageVersion.of(17)
14+
}
15+
}
1116

1217
repositories {
1318
mavenCentral()
@@ -20,11 +25,11 @@ dependencies {
2025
}
2126

2227
kotlin {
23-
jvmToolchain(17)
2428
compilerOptions {
25-
freeCompilerArgs.addAll("-Xjsr305=strict")
29+
freeCompilerArgs.addAll("-Xjsr305=strict", "-Xannotation-default-target=param-property")
2630
}
2731
}
32+
2833
tasks.test {
2934
useJUnitPlatform()
3035
}

complete-kotlin/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
rootProject.name = "relational-data-access"
1+
rootProject.name = "relational-data-access-complete"

complete/build.gradle

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,17 @@
11
plugins {
2-
id 'org.springframework.boot' version '3.5.7'
2+
id 'org.springframework.boot' version '4.0.0'
33
id 'io.spring.dependency-management' version '1.1.7'
44
id 'java'
55
}
66

77
group = 'com.example'
88
version = '0.0.1-SNAPSHOT'
9-
sourceCompatibility = '17'
9+
10+
java {
11+
toolchain {
12+
languageVersion = JavaLanguageVersion.of(17)
13+
}
14+
}
1015

1116
repositories {
1217
mavenCentral()

complete/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

complete/pom.xml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,13 @@
55
<parent>
66
<groupId>org.springframework.boot</groupId>
77
<artifactId>spring-boot-starter-parent</artifactId>
8-
<version>3.5.7</version>
8+
<version>4.0.0</version>
99
<relativePath/> <!-- lookup parent from repository -->
1010
</parent>
1111
<groupId>com.example</groupId>
1212
<artifactId>relational-data-access-complete</artifactId>
1313
<version>0.0.1-SNAPSHOT</version>
14-
<name>relational-data-access-complete</name>
15-
<description>Demo project for Spring Boot</description>
14+
1615
<properties>
1716
<java.version>17</java.version>
1817
</properties>

complete/settings.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
rootProject.name = 'relational-data-access'
1+
rootProject.name = 'relational-data-access-complete'

initial-kotlin/build.gradle.kts

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
11
plugins {
2-
id("org.springframework.boot") version "3.5.7"
2+
id("org.springframework.boot") version "4.0.0"
33
id("io.spring.dependency-management") version "1.1.7"
4-
kotlin("jvm") version "1.9.25"
5-
kotlin("plugin.spring") version "1.9.25"
4+
kotlin("jvm") version "2.2.21"
5+
kotlin("plugin.spring") version "2.2.21"
66
}
77

88
group = "com.example"
99
version = "0.0.1-SNAPSHOT"
10-
java.sourceCompatibility = JavaVersion.VERSION_17
10+
11+
java {
12+
toolchain {
13+
languageVersion = JavaLanguageVersion.of(17)
14+
}
15+
}
1116

1217
repositories {
1318
mavenCentral()
@@ -20,11 +25,11 @@ dependencies {
2025
}
2126

2227
kotlin {
23-
jvmToolchain(17)
2428
compilerOptions {
25-
freeCompilerArgs.addAll("-Xjsr305=strict")
29+
freeCompilerArgs.addAll("-Xjsr305=strict", "-Xannotation-default-target=param-property")
2630
}
2731
}
32+
2833
tasks.test {
2934
useJUnitPlatform()
3035
}

initial-kotlin/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

0 commit comments

Comments
 (0)