Hello,

I'm Moritz from the Spring Boot team.

I tried Maven 4.0.0-RC1 with a project which is a library for Spring Boot.
For this, I have to import the spring-boot-dependencies BOM with a scope
import in the dependency management section to align to the versions used
in Spring Boot.

When I install this with Maven 3, the POM in the local m2 repository
contains 33 lines of XML. When I install this with Maven 4.0.0-RC1, the
installed consumer POM is 7610 lines of XML, which amounts to 259 KiB. 7595
of those lines are <dependencyManagement> declarations copied from
spring-boot-dependencies. I only use one dependency from that
dependencyManagement section, spring-boot-autoconfigure.


I don't understand why the consumer POM has copied all of the managed
dependencies from spring-boot-dependencies, or why the consumer POM
contains dependencyManagement at all, because the dependency on
spring-boot-autoconfigure
is listed in the <dependency> section of the consumer POM with the correct
version 3.4.0.


I guess there's a reason for that that I just can't find. But it's still
worrisome that the consumer POM is 259 KiB of XML where the build POM is
only 1.1 KiB.


I've attached the POM I've been using.


Thanks,

Moritz

-- 
This electronic communication and the information and any files transmitted 
with it, or attached to it, are confidential and are intended solely for 
the use of the individual or entity to whom it is addressed and may contain 
information that is confidential, legally privileged, protected by privacy 
laws, or otherwise restricted from disclosure to anyone else. If you are 
not the intended recipient or the person responsible for delivering the 
e-mail to the intended recipient, you are hereby notified that any use, 
copying, distributing, dissemination, forwarding, printing, or copying of 
this e-mail is strictly prohibited. If you received this e-mail in error, 
please return the e-mail to the sender, delete it from your computer, and 
destroy any printed copy of it.
<project xmlns="http://maven.apache.org/POM/4.1.0"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
         xsi:schemaLocation="http://maven.apache.org/POM/4.1.0 http://maven.apache.org/xsd/maven-4.1.0.xsd"; root="true">

    <packaging>jar</packaging>

    <groupId>my.group</groupId>
    <artifactId>lib</artifactId>
    <version>1.0.0-SNAPSHOT</version>

    <properties>
        <spring-boot.version>3.4.0</spring-boot.version>
        <maven.compiler.release>17</maven.compiler.release>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-autoconfigure</artifactId>
        </dependency>
    </dependencies>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-dependencies</artifactId>
                <version>${spring-boot.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>
</project>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to