springboot
存天理 灭恶欲
这个作者很懒,什么都没留下…
展开
-
springboot日志配置
依赖 spring-boot-starter其中包含了 spring-boot-starter-logging,该依赖内容就是 Spring Boot 默认的日志框架 logback。 打印控制台 import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.web.bind.annota...原创 2019-08-22 10:12:43 · 426 阅读 · 0 评论 -
springboot-Web异常统一处理
创建自定义异常 import lombok.Data; @Data public class BaseException extends Exception { private String errCode; private String errMsg; public BaseException(String errMsg) { this.errMs...原创 2019-08-16 11:55:15 · 134 阅读 · 0 评论 -
springboot-集成mybaits和h2
加入依赖(mybatis和h2) <dependency> <groupId>org.mybatis.spring.boot</groupId> <artifactId>mybatis-spring-boot-starter</artifactId> <version>1.3.2</version&...原创 2019-08-22 14:49:52 · 2568 阅读 · 0 评论 -
springboot引入thymeleaf标签
<!DOCTYPE html> <html lang="en" xmlns:th="http://www.thymeleaf.org"> <head> <meta charset="UTF-8"> <title>股票历史数据</title> <script th:src="@{jquery-3.4...原创 2019-09-15 20:38:24 · 901 阅读 · 0 评论