zoukankan      html  css  js  c++  java
  • springbootstarterparent与springbootdependencies

    官方系统构建:https://docs.spring.io/spring-boot/docs/current/reference/html/using.html#using.build-systems

    使用maven构建聚合项目时,一般顶层的项目我们都没有引入parent包括spring-boot-starter-parent,很多时候顶层的项目就是其下子模块的parent,这个时候在子模块pom中是没法引入spring-boot-starter-parent的。这个时候,我们可以在顶层pom中引入spring-boot-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>
    

    不想使用spring-boot-starter-parent,你依然可以通过使用spring-boot-dependencies的scope=import利用依赖管理的便利。

    我们通过分析spring-boot-starter-parent发现它继承了spring-boot-dependencies,同时spring-boot-starter-parent提供了很多官方约定的功能
    在这里插入图片描述

  • 相关阅读:
    AES加解密
    redis HyperLogLog使用
    vi常用操作
    redis string使用
    用jdk命令定位java应用问题
    用户态、内核态及零拷贝
    缓存穿透与雪崩
    ReentrantLock、Semaphore、AQS
    redis list使用
    不同数据库取并集、交集、差集
  • 原文地址:https://www.cnblogs.com/InternetJava/p/15731286.html
Copyright © 2011-2022 走看看