What is the correct use of spring bom?

look at https://howtodoinjava.com/mav.. You don"t need to specify the version number after referencing zhihou, so it"s

.

< dependencyManagement >

<dependencies>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-framework-bom</artifactId>
        <version>4.3.7.RELEASE</version>
        <type>pom</type>
        <scope>import</scope>
    </dependency>
</dependencies> </dependencyManagement> <dependencies>
<dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-context</artifactId>
</dependency>
<dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-web</artifactId>
</dependency>

< / dependencies >

is equivalent to

< dependencies >

 <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context</artifactId>
        <version>4.3.7.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-web</artifactId>
        <version>4.3.7.RELEASE</version>
    </dependency> 

< / dependencies >

Does it mean

? If that"s all, it doesn"t seem to work.

Mar.25,2022

your spring systems are all the same, so the versions are all the same, so you don't seem to be of much use.
in fact, he also specifies a large number of third-party non-spring project versions to ensure that there are no version mismatches. This is the most practical


spring bom seems to have only developed its own version, and the usefulness of
with a third-party dependent version is Spring IO Platform. But the official website says that it is recommended to inherit spring-boot-starter-parent or use spring-boot-dependencies
. In fact, the advantage is that many dependencies do not need to write a version, and if you need to upgrade or downgrade, you can just upgrade bom (or parent project)

.
Menu