From ceefb553c41019bffe88ad9b8497f35032d50ba7 Mon Sep 17 00:00:00 2001 From: Hyunwoo Jung Date: Sun, 6 Sep 2026 09:54:18 +0900 Subject: [PATCH] Avoid using Project objects as dependency notation Gradle 9.6 deprecates passing a Project instance as dependency notation, which currently causes the build to emit deprecation warnings and will become an error in Gradle 10. This commit updates AggregatorPlugin to use DependencyFactory#createProjectDependency instead. Signed-off-by: Hyunwoo Jung See gh-51598 --- .../boot/build/aggregation/AggregatorPlugin.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/buildSrc/src/main/java/org/springframework/boot/build/aggregation/AggregatorPlugin.java b/buildSrc/src/main/java/org/springframework/boot/build/aggregation/AggregatorPlugin.java index ffe2baf527b..92e30f7c040 100644 --- a/buildSrc/src/main/java/org/springframework/boot/build/aggregation/AggregatorPlugin.java +++ b/buildSrc/src/main/java/org/springframework/boot/build/aggregation/AggregatorPlugin.java @@ -47,7 +47,8 @@ public class AggregatorPlugin implements Plugin { configureAttributes(configuration, aggregate, target.getObjects()); }); target.getRootProject() - .allprojects((project) -> target.getDependencies().add(dependencies.getName(), project)); + .allprojects((project) -> target.getDependencies() + .add(dependencies.getName(), project.getDependencyFactory().createProjectDependency())); aggregate.getFiles() .convention(aggregated.map((configuration) -> configuration.getIncoming() .artifactView((view) -> view.setLenient(true))