在spring配置文件中通过配置<context:annotation-config>,springboot 默认开启。