springboot项目配置文件详解二

第三部分(需要耐心,尽可能对信息简略写了,但为了保证完整性)

2019-01-24 14:22:57.744 [main] INFO  org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext [AbstractApplicationContext.java:590] - Refreshing org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext@207b8649: startup date [Thu Jan 24 14:22:57 CST 2019]; parent: org.springframework.context.annotation.AnnotationConfigApplicationContext@10959ece
2019-01-24 14:22:58.598 [main] INFO  org.springframework.data.repository.config.RepositoryConfigurationDelegate [RepositoryConfigurationDelegate.java:163] - Multiple Spring Data modules found, entering strict repository configuration mode!
2019-01-24 14:22:58.627 [main] DEBUG org.springframework.data.repository.config.RepositoryComponentProvider [ClassPathScanningCandidateComponentProvider.java:437] - Identified candidate component class: file [F:\oauth2\server\oauth-server\target\classes\com\wjx\authorization\repository\BasicLogRepository.class]
此处省略部分
2019-01-24 14:22:58.656 [main] DEBUG org.springframework.data.repository.config.RepositoryConfigurationDelegate [RepositoryConfigurationDelegate.java:137] - Spring Data JPA - Registering repository: errLogRepository - Interface: com.wjx.authorization.repository.ErrLogRepository - Factory: org.springframework.data.jpa.repository.support.JpaRepositoryFactoryBeann
2019-01-24 14:22:58.674 [main] INFO  org.springframework.data.repository.config.RepositoryConfigurationDelegate [RepositoryConfigurationDelegate.java:163] - Multiple Spring Data modules found, entering strict repository configuration mode!
2019-01-24 14:22:58.689 [main] DEBUG org.springframework.data.repository.config.RepositoryComponentProvider [ClassPathScanningCandidateComponentProvider.java:437] - Identified candidate component class: file 
2019-01-24 14:22:58.691 [main] INFO  org.springframework.data.repository.config.RepositoryConfigurationExtensionSupport [RepositoryConfigurationExtensionSupport.java:297] - Spring Data Redis - Could not safely identify store assignment for repository candidate interface com.wjx.authorization.repository.BasicLogRepository.(省略很多相同的地方)

说明:先找了org.springframework.boot.web.servlet.context中AnnotationConfigServletWebServerApplicationContext自动化注解webServlet应用链接信息(其实对应着是@SpringBootApplication注解,AnnotationConfigApplicationContext也是),我的主类如下:

springboot项目配置文件详解二_第1张图片

下一步果然是扫描了(不知道是偶然还是按着这个顺序)MapperScan,对包内JPA以及构造器进行JpaRepositoryFactoryBean工厂Bean构建

第四部分

2019-01-24 14:22:59.046 [main] INFO  org.springframework.cloud.context.scope.GenericScope [GenericScope.java:294] - BeanFactory id=bf647a79-0a1d-3afe-8dba-d4c5659a7d0d
2019-01-24 14:22:59.066 [main] INFO  com.ulisesbocchio.jasyptspringboot.configuration.EnableEncryptablePropertiesBeanFactoryPostProcessor [EnableEncryptablePropertiesBeanFactoryPostProcessor.java:50] - Post-processing PropertySource instances
2019-01-24 14:22:59.174 [main] INFO  com.ulisesbocchio.jasyptspringboot.EncryptablePropertySourceConverter                                           +其他多余pid38线程东西

[EncryptablePropertySourceConverter.java:38] - Converting PropertySource defaultProperties [org.springframework.core.env.MapPropertySource] to EncryptableMapPropertySourceWrapper
2019-01-24 14:22:59.189 [main] INFO  org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor [AutowiredAnnotationBeanPostProcessor.java:153] - JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2019-01-24 14:22:59.235 [main] INFO  com.ulisesbocchio.jasyptspringboot.filter.DefaultLazyPropertyFilter [DefaultLazyPropertyFilter.java:31] - Property Filter custom Bean not found with name 'encryptablePropertyFilter'. Initializing Default Property Filter
2019-01-24 14:22:59.336 [main] INFO  org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker [PostProcessorRegistrationDelegate.java:326] - Bean 'org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration' of type [org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration$$EnhancerBySpringCGLIB$$89f749a3] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2019-01-24 14:22:59.481 [main] INFO  com.ulisesbocchio.jasyptspringboot.resolver.DefaultLazyPropertyResolver [DefaultLazyPropertyResolver.java:31] - Property Resolver custom Bean not found with name 'encryptablePropertyResolver'. Initializing Default Property Resolver
+jasyptStringEncryptor的一些属性

说明:GenericScope通用范围作用域,只知道应该是cloud注解的东西(有兴趣的同学可以看源码深入研究),接下来jasyptspringboot类解析(可能在读取cloud服务时为了解析再读取一遍)

接着读取source资源,又采用encryptablePropertyFilter对文件解析了一遍,基本证明我上面的猜测是正确的

第五部分

2019-01-24 14:22:59.612 [main] INFO  org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker [PostProcessorRegistrationDelegate.java:326] - Bean 'spring.redis-org.springframework.boot.autoconfigure.data.redis.RedisProperties' of type [org.springframework.boot.autoconfigure.data.redis.RedisProperties] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
 org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker 

说明:此处是属于redis配置,因为我在配置后又将主键序列化和TedisCacheManager重写了一遍,所以表示不符合由所有BeanPostProcessor处理的条件,关于redis本想做集群化处理,但是业务上不需要所以放弃了

第6部分
2019-01-24 14:23:00.542 [main] INFO  org.springframework.boot.web.embedded.tomcat.TomcatWebServer [TomcatWebServer.java:91] - Tomcat initialized with port(s): 8016 (http)
2019-01-24 14:23:00.553 [main] INFO  org.apache.coyote.http11.Http11NioProtocol [DirectJDKLog.java:180] - Initializing ProtocolHandler ["http-nio-8016"]
2019-01-24 14:23:00.564 [main] INFO  org.apache.catalina.core.StandardService [DirectJDKLog.java:180] - Starting service [Tomcat]
2019-01-24 14:23:00.564 [main] INFO  org.apache.catalina.core.StandardEngine [DirectJDKLog.java:180] - Starting Servlet Engine: Apache Tomcat/8.5.32
2019-01-24 14:23:00.569 [localhost-startStop-1] INFO  org.apache.catalina.core.AprLifecycleListener [DirectJDKLog.java:180] - The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [C:\Program +一些jar]
2019-01-24 14:23:00.862 [localhost-startStop-1] INFO  org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/] [DirectJDKLog.java:180] - Initializing Spring embedded WebApplicationContext
2019-01-24 14:23:00.863 [localhost-startStop-1] INFO  org.springframework.web.context.ContextLoader [ServletWebServerApplicationContext.java:285] - Root WebApplicationContext: initialization completed in 3119 ms
2019-01-24 14:23:01.098 [localhost-startStop-1] WARN  com.netflix.config.sources.URLConfigurationSource [URLConfigurationSource.java:121] - No URLs will be polled as dynamic configuration sources.
2019-01-24 14:23:01.099 [localhost-startStop-1] INFO  com.netflix.config.sources.URLConfigurationSource [URLConfigurationSource.java:122] - To enable URLs as dynamic configuration sources, define System property archaius.configurationSource.additionalUrls or make config.properties available on classpath.

说明:启动tomcat,实例加载ServletWebServerApplicationContext的servlet应用上下文链接对象,又警告了一遍URL没找到

第7部分

2019-01-24 14:23:01.108 [localhost-startStop-1] INFO  com.netflix.config.DynamicPropertyFactory [DynamicPropertyFactory.java:281] - DynamicPropertyFactory is initialized with configuration sources: com.netflix.config.ConcurrentCompositeConfiguration@563e5bcd
2019-01-24 14:23:02.191 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.FilterRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'characterEncodingFilter' to: [/*]
2019-01-24 14:23:02.191 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.FilterRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'webMvcMetricsFilter' to: [/*]
2019-01-24 14:23:02.192 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.FilterRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2019-01-24 14:23:02.192 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.FilterRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'httpPutFormContentFilter' to: [/*]
2019-01-24 14:23:02.192 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.FilterRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'requestContextFilter' to: [/*]
2019-01-24 14:23:02.192 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.DelegatingFilterProxyRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'springSecurityFilterChain' to: [/*]
2019-01-24 14:23:02.193 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.FilterRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'httpTraceFilter' to: [/*]
2019-01-24 14:23:02.193 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.FilterRegistrationBean [AbstractFilterRegistrationBean.java:245] - Mapping filter: 'corsFilter' to: [/*]
2019-01-24 14:23:02.193 [localhost-startStop-1] INFO  org.springframework.boot.web.servlet.ServletRegistrationBean [ServletRegistrationBean.java:187] - Servlet proxyStreamServlet mapped to [/proxy.stream]

说明:FilterRegistrationBean属于 org.springframework.boot.web.servlet报下

springboot项目配置文件详解二_第2张图片

属于Filter接口子类,有空参构造方法和包含ServletRegistrationBean构造方法2种,因此也扩展上面多种Filter类拦截器接口(都可以写实例方法来实现拦截请求)

第八部分

2019-01-24 14:23:02.367 [main] INFO  com.alibaba.druid.pool.DruidDataSource [Log4j2Impl.java:106] - {dataSource-1} inited
2019-01-24 14:23:02.544 [main] INFO  org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean [LocalContainerEntityManagerFactoryBean.java:361] - Building JPA container EntityManagerFactory for persistence unit 'default'
2019-01-24 14:23:02.556 [main] INFO  org.hibernate.jpa.internal.util.LogHelper [LogHelper.java:31] - HHH000204: Processing PersistenceUnitInfo [
    name: default
    ...]
2019-01-24 14:23:02.621 [main] INFO  org.hibernate.Version [Version.java:45] - HHH000412: Hibernate Core {5.2.17.Final}
2019-01-24 14:23:02.622 [main] INFO  org.hibernate.cfg.Environment [Environment.java:213] - HHH000206: hibernate.properties not found
2019-01-24 14:23:02.666 [main] INFO  org.hibernate.annotations.common.Version [JavaReflectionManager.java:66] - HCANN000001: Hibernate Commons Annotations {5.0.1.Final}
2019-01-24 14:23:02.836 [main] INFO  org.hibernate.dialect.Dialect [Dialect.java:157] - HHH000400: Using dialect: org.hibernate.dialect.MySQL5Dialect
2019-01-24 14:23:03.454 [main] INFO  org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean [AbstractEntityManagerFactoryBean.java:415] - Initialized JPA EntityManagerFactory for persistence unit 'default'
2019-01-24 14:23:03.750 [main] DEBUG org.springframework.data.jpa.repository.query.JpaQueryFactory [JpaQueryFactory.java:55] - Looking up query for method DeleteBasicLog
2019-01-24 14:23:03.772 [main] INFO  org.hibernate.hql.internal.QueryTranslatorFactoryInitiator [QueryTranslatorFactoryInitiator.java:47] - HHH000397: Using ASTQueryTranslatorFactory
2019-01-24 14:23:03.843 [main] DEBUG org.springframework.data.jpa.repository.query.JpaQueryFactory [JpaQueryFactory.java:55] - Looking up query for method getBasicLogsByCondition
2019-01-24 14:23:03.857 [main] DEBUG org.springframework.data.jpa.repository.query.JpaQueryFactory [JpaQueryFactory.java:55] - Looking up query for method getCountByArgs
2019-01-24 14:23:03.906 [main] INFO  com.wjx.authorization.adapter.controller.common.config.RedisConfig [RedisConfig.java:107] - redis: org.springframework.data.redis.connection.lettuce.LettuceConnectionFactory@48cd319d
2019-01-24 14:23:03.906 [main] INFO  com.wjx.authorization.adapter.controller.common.config.RedisConfig [RedisConfig.java:109] - spring.redis.database: 0
+redis配置信息
2019-01-24 14:23:04.341 [main] DEBUG org.springframework.data.jpa.repository.query.JpaQueryFactory [JpaQueryFactory.java:55] - Looking up query for method DeleteExternalInterfaceLog
+jpa方法

说明:这里面比较简单,又是对JPA方法注解进行扫描,同时redis配置信息。

本章太长了,只好换第三章并对其进行总结

 

 

 

你可能感兴趣的:(cloud)