Spring Boot 运行原理
来源:互联网 发布:apache服务器搭建 编辑:程序博客网 时间:2024/06/06 00:14
1 查看Spring Boot自动配置项
Spring Boot 自动配置源代码在spring-boot-autoconfigure-1.5.3.RELEASE.jar内,如图:
如果想知道Spring Boot做了那些自动配置可以在这里看源码。
可以通过下面三种方式查看当前项目中已启用和未启动的自动配置报告:
- 运行jar时添加--debug参数:
java -jar xx.jar --debug
- 在application.properties文件中加属性:
debug=true
- 在STS中进行设置,如图:
此时启动会在控制台输出,已启用的自动配置:
=========================AUTO-CONFIGURATION REPORT=========================Positive matches:----------------- DefaultValidatorConfiguration#defaultValidator matched: - @ConditionalOnMissingBean (types: javax.validation.Validator,org.springframework.validation.Validator; SearchStrategy: all) did not find any beans (OnBeanCondition) DispatcherServletAutoConfiguration matched: - @ConditionalOnClass found required class 'org.springframework.web.servlet.DispatcherServlet'; @ConditionalOnMissingClass did not find unwanted class (OnClassCondition) - @ConditionalOnWebApplication (required) found StandardServletEnvironment (OnWebApplicationCondition) DispatcherServletAutoConfiguration.DispatcherServletConfiguration matched: - @ConditionalOnClass found required class 'javax.servlet.ServletRegistration'; @ConditionalOnMissingClass did not find unwanted class (OnClassCondition) - Default DispatcherServlet did not find dispatcher servlet beans (DispatcherServletAutoConfiguration.DefaultDispatcherServletCondition)...
未启用的自动配置:
Negative matches:----------------- ActiveMQAutoConfiguration: Did not match: - @ConditionalOnClass did not find required classes 'javax.jms.ConnectionFactory', 'org.apache.activemq.ActiveMQConnectionFactory' (OnClassCondition) AopAutoConfiguration: Did not match: - @ConditionalOnClass did not find required classes 'org.aspectj.lang.annotation.Aspect', 'org.aspectj.lang.reflect.Advice' (OnClassCondition)...
以排除的自动配置
Exclusions:----------- None
无条件类:
Unconditional classes:---------------------- org.springframework.boot.autoconfigure.context.ConfigurationPropertiesAutoConfiguration org.springframework.boot.autoconfigure.web.WebClientAutoConfiguration org.springframework.boot.autoconfigure.context.PropertyPlaceholderAutoConfiguration org.springframework.boot.autoconfigure.info.ProjectInfoAutoConfiguration
0 0
- Spring Boot 运行原理
- Spring Boot 运行原理
- Spring Boot 运行原理
- Spring Boot 运行原理
- Spring Boot 运行原理
- Spring Boot运行原理
- spring boot-2(运行原理)
- spring boot 原理、demo 与打包运行
- 3Spring Boot 运行原理,自动配置
- Spring Boot WAR包运行原理分析
- Spring Boot 运行原理之自动配置
- SpringBoot15-springboot核心-Spring Boot运行原理
- spring boot 运行jsp原理分析
- SpringBoot学习笔记(3) Spring Boot 运行原理,自动配置
- Java微框架Spring Boot 运行原理深入解读
- SpringBoot学习笔记(3) Spring Boot 运行原理,自动配置
- Spring Boot Application 运行
- spring boot 启用原理
- Ubuntu磁盘空间告警,tmp目录出现overflow的解决方案
- threejs在线编辑器
- python升级2.6.6-->2.7.3引起的pip和easy_install执行错误
- Bootstrap警告面板
- 动效神器 Origami Studio 汉化
- Spring Boot 运行原理
- Android CardView 和Material Design风格设计学习
- 二叉排序树的实现
- Android 利用layoutParams代码动态布局空间位置
- 字符串匹配-KMP
- 华为手机logcat不出日志解决方案
- Ubuntu
- Linux安装apache详解
- javascript第5章