Skip to content

Commit aefe52e

Browse files
committed
Revert "Rework dep management to avoid consumers picking up strict constraints"
This reverts commit b34a311 as, having disabled the publishing of Gradle's module metadata (4f75ab5), the changes are no longer needed. See gh-19609
1 parent 4f75ab5 commit aefe52e

File tree

78 files changed

+102
-188
lines changed

Some content is hidden

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

78 files changed

+102
-188
lines changed

buildSrc/build.gradle

-4
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,6 @@ gradlePlugin {
5252
id = "org.springframework.boot.conventions"
5353
implementationClass = "org.springframework.boot.build.ConventionsPlugin"
5454
}
55-
dependencyManagementPlugin {
56-
id = "org.springframework.boot.internal-dependency-management"
57-
implementationClass = "org.springframework.boot.build.InternalDependencyManagementPlugin"
58-
}
5955
deployedPlugin {
6056
id = "org.springframework.boot.deployed"
6157
implementationClass = "org.springframework.boot.build.DeployedPlugin"

buildSrc/src/main/java/org/springframework/boot/build/InternalDependencyManagementPlugin.java

-60
This file was deleted.

buildSrc/src/main/java/org/springframework/boot/build/bom/BomExtension.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ private void addLibrary(Library library) {
113113
for (String bomImport : group.getBoms()) {
114114
this.putArtifactVersionProperty(group.getId(), bomImport, library.getVersionProperty());
115115
this.dependencyHandler.add("api", this.dependencyHandler
116-
.platform(createDependencyNotation(group.getId(), bomImport, library.getVersion())));
116+
.enforcedPlatform(createDependencyNotation(group.getId(), bomImport, library.getVersion())));
117117
}
118118
}
119119
}

buildSrc/src/main/java/org/springframework/boot/build/starters/StarterPlugin.java

-2
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929

3030
import org.springframework.boot.build.ConventionsPlugin;
3131
import org.springframework.boot.build.DeployedPlugin;
32-
import org.springframework.boot.build.InternalDependencyManagementPlugin;
3332
import org.springframework.boot.build.classpath.CheckClasspathForConflicts;
3433
import org.springframework.boot.build.classpath.CheckClasspathForProhibitedDependencies;
3534
import org.springframework.util.StringUtils;
@@ -47,7 +46,6 @@ public void apply(Project project) {
4746
plugins.apply(DeployedPlugin.class);
4847
plugins.apply(JavaLibraryPlugin.class);
4948
plugins.apply(ConventionsPlugin.class);
50-
plugins.apply(InternalDependencyManagementPlugin.class);
5149
StarterMetadata starterMetadata = project.getTasks().create("starterMetadata", StarterMetadata.class);
5250
ConfigurationContainer configurations = project.getConfigurations();
5351
Configuration runtimeClasspath = configurations.getByName(JavaPlugin.RUNTIME_CLASSPATH_CONFIGURATION_NAME);

spring-boot-project/spring-boot-actuator-autoconfigure/build.gradle

+3-5
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ plugins {
55
id 'org.springframework.boot.auto-configuration'
66
id 'org.springframework.boot.conventions'
77
id 'org.springframework.boot.deployed'
8-
id 'org.springframework.boot.internal-dependency-management'
98
id 'org.springframework.boot.optional-dependencies'
109
}
1110

@@ -17,21 +16,20 @@ configurations {
1716
}
1817

1918
dependencies {
20-
asciidoctorExtensions platform(project(':spring-boot-project:spring-boot-dependencies'))
19+
asciidoctorExtensions enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
2120
asciidoctorExtensions 'org.springframework.restdocs:spring-restdocs-asciidoctor'
2221

23-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
24-
2522
api project(':spring-boot-project:spring-boot-actuator')
2623

24+
implementation enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
2725
implementation project(':spring-boot-project:spring-boot')
2826
implementation project(':spring-boot-project:spring-boot-autoconfigure')
2927
implementation 'com.fasterxml.jackson.core:jackson-databind'
3028
implementation 'com.fasterxml.jackson.datatype:jackson-datatype-jsr310'
3129
implementation 'org.springframework:spring-core'
3230
implementation 'org.springframework:spring-context'
3331

34-
optional platform(project(':spring-boot-project:spring-boot-dependencies'))
32+
optional enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
3533
optional 'ch.qos.logback:logback-classic'
3634
optional 'com.fasterxml.jackson.dataformat:jackson-dataformat-xml'
3735
optional 'com.github.ben-manes.caffeine:caffeine'

spring-boot-project/spring-boot-actuator/build.gradle

+2-3
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,10 @@ plugins {
99
description = 'Spring Boot Actuator'
1010

1111
dependencies {
12-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
13-
12+
implementation enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
1413
implementation project(':spring-boot-project:spring-boot')
1514

16-
optional platform(project(':spring-boot-project:spring-boot-dependencies'))
15+
optional enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
1716
optional 'com.fasterxml.jackson.core:jackson-databind'
1817
optional 'com.hazelcast:hazelcast'
1918
optional 'com.hazelcast:hazelcast-spring'

spring-boot-project/spring-boot-autoconfigure/build.gradle

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,17 @@ plugins {
44
id 'org.springframework.boot.auto-configuration'
55
id 'org.springframework.boot.conventions'
66
id 'org.springframework.boot.deployed'
7-
id 'org.springframework.boot.internal-dependency-management'
87
id 'org.springframework.boot.optional-dependencies'
98
}
109

1110
description = 'Spring Boot AutoConfigure'
1211

1312
dependencies {
1413
api project(':spring-boot-project:spring-boot')
15-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
1614

17-
optional platform(project(':spring-boot-project:spring-boot-dependencies'))
15+
implementation enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
16+
17+
optional enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
1818
optional 'com.atomikos:transactions-jdbc'
1919
optional 'com.atomikos:transactions-jta'
2020
optional 'com.couchbase.client:couchbase-spring-cache'
@@ -148,7 +148,7 @@ dependencies {
148148
optional 'org.thymeleaf.extras:thymeleaf-extras-springsecurity5'
149149
optional 'redis.clients:jedis'
150150

151-
testImplementation platform(project(':spring-boot-project:spring-boot-parent'))
151+
testImplementation enforcedPlatform(project(':spring-boot-project:spring-boot-parent'))
152152
testImplementation project(':spring-boot-project:spring-boot-tools:spring-boot-test-support')
153153
testImplementation project(':spring-boot-project:spring-boot-test')
154154
testImplementation 'ch.qos.logback:logback-classic'

spring-boot-project/spring-boot-cli/build.gradle

+4-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ plugins {
33
id 'org.springframework.boot.deployed'
44
id 'org.springframework.boot.conventions'
55
id 'org.springframework.boot.integration-test'
6-
id 'org.springframework.boot.internal-dependency-management'
76
}
87

98
description = "Spring Boot CLI"
@@ -16,14 +15,16 @@ configurations {
1615

1716
dependencies {
1817
compileOnly project(':spring-boot-project:spring-boot')
18+
1919
compileOnly 'jakarta.servlet:jakarta.servlet-api'
2020
compileOnly 'org.codehaus.groovy:groovy-templates'
2121
compileOnly 'org.springframework:spring-web'
2222

2323
dependenciesBom project(path: ':spring-boot-project:spring-boot-dependencies', configuration: 'effectiveBom')
2424

25-
implementation platform(project(':spring-boot-project:spring-boot-parent'))
25+
implementation enforcedPlatform(project(':spring-boot-project:spring-boot-parent'))
2626
implementation project(':spring-boot-project:spring-boot-tools:spring-boot-loader-tools')
27+
2728
implementation 'com.vaadin.external.google:android-json'
2829
implementation 'jline:jline'
2930
implementation 'net.sf.jopt-simple:jopt-simple'
@@ -50,7 +51,7 @@ dependencies {
5051
implementation 'org.springframework:spring-core'
5152
implementation 'org.springframework.security:spring-security-crypto'
5253

53-
intTestImplementation platform(project(':spring-boot-project:spring-boot-dependencies'))
54+
intTestImplementation enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
5455
intTestImplementation project(':spring-boot-project:spring-boot-tools:spring-boot-loader-tools')
5556
intTestImplementation project(':spring-boot-project:spring-boot-tools:spring-boot-test-support')
5657
intTestImplementation 'org.assertj:assertj-core'

spring-boot-project/spring-boot-devtools/build.gradle

+3-4
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ plugins {
44
id 'org.springframework.boot.conventions'
55
id 'org.springframework.boot.deployed'
66
id 'org.springframework.boot.integration-test'
7-
id 'org.springframework.boot.internal-dependency-management'
87
id 'org.springframework.boot.optional-dependencies'
98
}
109

@@ -15,13 +14,13 @@ configurations {
1514
}
1615

1716
dependencies {
18-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
19-
17+
implementation enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
2018
implementation project(':spring-boot-project:spring-boot')
2119
implementation project(':spring-boot-project:spring-boot-autoconfigure')
2220

2321
intTestDependencies project(':spring-boot-project:spring-boot-starters:spring-boot-starter-web')
2422

23+
intTestImplementation enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
2524
intTestImplementation project(':spring-boot-project:spring-boot-autoconfigure')
2625
intTestImplementation project(':spring-boot-project:spring-boot-test')
2726
intTestImplementation project(':spring-boot-project:spring-boot-tools:spring-boot-test-support')
@@ -32,7 +31,7 @@ dependencies {
3231
intTestImplementation 'net.bytebuddy:byte-buddy'
3332
intTestRuntimeOnly 'org.springframework:spring-web'
3433

35-
optional platform(project(':spring-boot-project:spring-boot-dependencies'))
34+
optional enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
3635
optional 'javax.servlet:javax.servlet-api'
3736
optional 'org.apache.derby:derby'
3837
optional 'org.hibernate:hibernate-core'

spring-boot-project/spring-boot-properties-migrator/build.gradle

+1-3
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,12 @@ plugins {
22
id 'java-library'
33
id 'maven-publish'
44
id 'org.springframework.boot.conventions'
5-
id 'org.springframework.boot.internal-dependency-management'
65
}
76

87
description = 'Spring Boot Properties Migrator'
98

109
dependencies {
11-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
12-
10+
implementation enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
1311
implementation project(':spring-boot-project:spring-boot')
1412
implementation project(':spring-boot-project:spring-boot-tools:spring-boot-configuration-metadata')
1513

spring-boot-project/spring-boot-starters/spring-boot-starter-activemq/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for JMS messaging using Apache ActiveMQ"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'org.springframework:spring-jms'
1111
api ('org.apache.activemq:activemq-broker') {

spring-boot-project/spring-boot-starters/spring-boot-starter-actuator/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Spring Boot's Actuator which provides production ready features to help you monitor and manage your application"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api project(':spring-boot-project:spring-boot-actuator-autoconfigure')
1111
api 'io.micrometer:micrometer-core'

spring-boot-project/spring-boot-starters/spring-boot-starter-amqp/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Spring AMQP and Rabbit MQ"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'org.springframework:spring-messaging'
1111
api 'org.springframework.amqp:spring-rabbit'

spring-boot-project/spring-boot-starters/spring-boot-starter-aop/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for aspect-oriented programming with Spring AOP and AspectJ"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'org.springframework:spring-aop'
1111
api 'org.aspectj:aspectjweaver'

spring-boot-project/spring-boot-starters/spring-boot-starter-artemis/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for JMS messaging using Apache Artemis"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'jakarta.jms:jakarta.jms-api'
1111
api 'jakarta.json:jakarta.json-api'

spring-boot-project/spring-boot-starters/spring-boot-starter-batch/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Spring Batch"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter-jdbc')
1111
api 'org.springframework.batch:spring-batch-core'

spring-boot-project/spring-boot-starters/spring-boot-starter-cache/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Spring Framework's caching support"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'org.springframework:spring-context-support'
1111
}

spring-boot-project/spring-boot-starters/spring-boot-starter-cloud-connectors/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Spring Cloud Connectors which simplifies connecting to services in cloud platforms like Cloud Foundry and Heroku"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'org.springframework.cloud:spring-cloud-spring-service-connector'
1111
api 'org.springframework.cloud:spring-cloud-cloudfoundry-connector'

spring-boot-project/spring-boot-starters/spring-boot-starter-data-cassandra-reactive/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Cassandra distributed database and Spring Data Cassandra Reactive"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'org.springframework:spring-tx'
1111
api 'org.springframework.data:spring-data-cassandra'

spring-boot-project/spring-boot-starters/spring-boot-starter-data-cassandra/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Cassandra distributed database and Spring Data Cassandra"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'org.springframework:spring-tx'
1111
api 'org.springframework.data:spring-data-cassandra'

spring-boot-project/spring-boot-starters/spring-boot-starter-data-couchbase-reactive/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Couchbase document-oriented database and Spring Data Couchbase Reactive"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api 'io.projectreactor:reactor-core'
1111
api 'io.reactivex:rxjava-reactive-streams'

spring-boot-project/spring-boot-starters/spring-boot-starter-data-couchbase/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Couchbase document-oriented database and Spring Data Couchbase"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api ('org.springframework.data:spring-data-couchbase') {
1111
exclude group: 'com.couchbase.client', module: 'encryption'

spring-boot-project/spring-boot-starters/spring-boot-starter-data-elasticsearch/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Elasticsearch search and analytics engine and Spring Data Elasticsearch"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter')
1010
api ('org.springframework.data:spring-data-elasticsearch') {
1111
exclude group: 'org.elasticsearch.client', module: 'transport'

spring-boot-project/spring-boot-starters/spring-boot-starter-data-jdbc/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ plugins {
55
description = "Starter for using Spring Data JDBC"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter-jdbc')
1010
api 'org.springframework.data:spring-data-jdbc'
1111
}

spring-boot-project/spring-boot-starters/spring-boot-starter-data-jpa/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@ plugins {
55
description = "Starter for using Spring Data JPA with Hibernate"
66

77
dependencies {
8-
api platform(project(':spring-boot-project:spring-boot-dependencies'))
8+
api enforcedPlatform(project(':spring-boot-project:spring-boot-dependencies'))
99
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter-aop')
1010
api project(':spring-boot-project:spring-boot-starters:spring-boot-starter-jdbc')
1111
api 'jakarta.transaction:jakarta.transaction-api'
1212
api 'jakarta.persistence:jakarta.persistence-api'
13-
api ('org.hibernate:hibernate-core') {
13+
api ('org.hibernate:hibernate-core') {
1414
exclude group: 'javax.activation', module: 'javax.activation-api'
1515
exclude group: 'javax.persistence', module: 'javax.persistence-api'
1616
exclude group: 'javax.xml.bind', module: 'jaxb-api'

0 commit comments

Comments
 (0)