尾记:spring加载这个bean后要直接调用其中的一个方法,可以使用@postconstruct注解。在使用@Value,可以指定默认值,比如@Value("${local-repository:/repository/}") ,红色部分为默认值。