1、@EnableConfigurationProperties=@component+@ConfigurationProperties
此时容器中并没有改组件,在此处可以加一个@component即可放入容器中当作组件使用(其实也可以配合任何可以将一个类注册为bean的注解一起使用,Springboot内部经常配合@Bean一起使用。)
或者是在其他地方加入@EnableConfigurationProperties,把ComponentProperties这个组件自动注册到容器中
@PropertySource相关使用看https://blog.csdn.net/qq_37312838/article/details/108237678