I tried to read documents regarding Spring BOM, Spring Boot and Spring IO.
But there is no clarification on, how we should use them together or not?
In my project, we already have our own Parent POM, So I can’t use as parent them but all they have alternative way to use, Like below by defining dependency management
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-framework-bom</artifactId>
<version>${org.springframework-version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<!-- Import dependency management from Spring Boot -->
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>1.2.5.RELEASE</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
Spring BOM, Spring Boot and Spring IO resolve version required for you
So what is exactly difference between them? Which one should I prefer? And in Which condition?
The Spring Framework bom provides dependency management for all of Spring Framework's modules. The Spring Boot bom is a superset of this. In addition to providing dependency management for Spring Framework, it also provides dependency management for Spring Boot's modules, a number of other Spring projects, and various third-party dependencies which Spring Boot supports. The Spring IO Platform bom is, in turn, a superset of the Spring Boot bom. The main change is that it adds dependency management for all of the Spring projects' dependencies.
If you're not using Spring Boot, or if you want to use your own dependency management, then you may want to use the Spring Framework bom . If you're using Spring Boot, or you want some help with dependency management, then you should choose between using Spring Boot's bom or the Spring IO Platform bom. The main choice here is how close to the leading edge you want to be. If you favour being up-to-date then use the Spring Boot bom. If your project is more conservative and backwards compatibility is of paramount importance, then you should consider using the Spring IO platform bom.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With