【Spring Boot】1、Spring Boot准备操作

1、Spring Boot 简介

简化Spring应用开发的一个框架;

整个Spring技术栈的一个大整合;

J2EE开发的一站式解决方案;、

2、微服务

2014,martin fowler

微服务:架构风格(服务微化)

一个应用应该是一组小型服务;可以通过HTTP的方式进行互通;

单体应用:ALL IN ONE

微服务:每一个功能元素最终都是一个可独立替换和独立升级的软件单元;

3、环境准备

SpringBoot2.0环境约束

  • jdk1.8+;java version “1.8.0_112”
  • maven 3.3+;Apache Maven 3.5.4
  • A favorite text editor or IDE:IntelliJ IDEA 2018.2.6
  • SpringBoot 2.1.1.RELEASE

4、Maven配置

$M2_HOME\conf\settings.xml 配置文件t添加如下内容

  • 在之间添加如下内容

  • 作用:国内maven仓库镜像(众所周知的原因国内不能很好的访问maven中央仓库)

    <mirror>
        <id>alimaven</id>
        <name>aliyun maven</name>
        <url>http://maven.aliyun.com/nexus/content/groups/public/</url>
        <mirrorOf>central</mirrorOf>        
    </mirror>
    
  • 在 之间添加如下内容

  • 作用:指定项目编译运行使用的JDK版本

    <profile>
        <id>jdk-1.8</id>
        <activation>
            <jdk>1.8</jdk>
            <activeByDefault>true</activeByDefault>
        </activation>
        <properties>
            <maven.compiler.source>1.8</maven.compiler.source>
            <maven.compiler.target>1.8</maven.compiler.target>
            <maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion>
        </properties>
        <!-- 如果是在学校或公司有maven私服,可以在这里配置私服 -->
        <repositories>
            <repository>
                <id>accp</id>
                <name>accp</name>
                <url>http://192.168.1.48:8081/repository/accp/</url>
                <snapshots>
                    <enabled>true</enabled>
                </snapshots>
                <releases>
                    <enabled>true</enabled>
                </releases>
            </repository>
        </repositories>
        <!-- 如果没有私服,这里不用配置 -->
    </profile>
    

5、修改Banner

文字Banner可以从这个网站生成(有很多种字体样式可以选择)

http://patorjk.com/software/taag

${AnsiColor.BLUE} 表示Banner文字的颜色

${spring-boot.version} 当前使用的SpringBoot版本

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值