logo资料库

SpringBoot开发小而美的个人博客.pdf

第1页 / 共18页
第2页 / 共18页
第3页 / 共18页
第4页 / 共18页
第5页 / 共18页
第6页 / 共18页
第7页 / 共18页
第8页 / 共18页
资料共18页,剩余部分请下载后查看
Spring Boot开发小而美的个人博客
1、需求与功能
1.1 用户故事
1.2 功能规划
2、页面设计与开发
2.1 设计
2.2 页面开发
2.3 插件集成
3、框架搭建
3.1 构建与配置
3.2 异常处理
3.3 日志处理
3.4 页面处理
4.1 实体设计
4.2 应用分层
4.3 命名约定
5、后台管理功能实现
5.1 登录
5.2 分类管理
5.3 标签管理
5.4 博客管理
6、前端展示功能实现
6.1 首页展示
6.2 分类页
6.3 标签页
6.4 归档页
6.5 关于我
Spring Boot Spring Boot + JPA + thymeleaf MySQL UISemantic UI IDEA Maven 3 JDK 8 Axure RP 8
Spring Boot Semantic UI 1 1.1 As a (role of user), I want (some feature) so that (some business value). () () () 3 6 10
1.2
2 2.1 2.2 Semantic UI Semantic UI WebStorm 2.3 Markdown
typo.css animate.css prism Tocbot waypoints jquery.scrollTo qrcode.js 3 IDEA https://www.jetbrains.com/idea/ 3.1 1Spring Boot web Thymeleaf JPA MySQL Aspects DevTools 2application.yml thymeleaf 3 pom.xml: 3.0.2.RELEASE 2.1.1 application.yml: spring: thymeleaf: mode: HTML
spring: datasource: driver-class-name: com.mysql.jdbc.Driver url: jdbc:mysql://localhost:3306/blog? useUnicode=true&characterEncoding=utf-8 username: root password: root jpa: hibernate: ddl-auto: update show-sql: true application.yml: logging: level: root: info com.imcoding: debug file: log/imcoding.log ​ logback-spring.xml ${FILE_LOG_PATTERN} ${LOG_FILE} ${LOG_FILE}.%d{yyyy-MM- dd}.%i
30 10MB application-dev.yml application-pro.yml 3.2 1 404 500 error 2
@ControllerAdvice public class ControllerExceptionHandler { private final Logger logger = LoggerFactory.getLogger(ControllerExceptionHandler.class); /** * * @param request * @param e * @return */ @ExceptionHandler({Exception.class}) public ModelAndView handleException(HttpServletRequest request, Exception e) throws Exception { logger.error("Request URL : {} , Exception : {}", request.getRequestURL(), e); if (AnnotationUtils.findAnnotation(e.getClass(), ResponseStatus.class) != null) { throw e; } ModelAndView mav = new ModelAndView(); mav.addObject("url", request.getRequestURL()); mav.addObject("exception", e); mav.setViewName("error/error"); return mav; } }
分享到:
收藏