初始化内存定义全局变量

public static Map<String, String> regionMap = new HashMap<>();

1、实现CommandLineRunner类,重写run方法

2、实现InitializingBean类,重新afterPropertiesSet方法,但bean需要通过set构造方法注入

3、通过构造方法注入

@PostConstruct
public void init() {
    log.info("----初始化系统参数----");
}