Commit d0af6650a725cf00d181c899da842d0a958f77a1

Authored by zhangdaiscott
1 parent 5846cb03

[issues/I561IU]3.2版本,跑测试用例代码抛出异常

jeecg-boot/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/config/WebMvcConfiguration.java
... ... @@ -14,6 +14,7 @@ import org.springframework.boot.autoconfigure.jackson.Jackson2ObjectMapperBuilde
14 14 import org.springframework.context.annotation.Bean;
15 15 import org.springframework.context.annotation.Conditional;
16 16 import org.springframework.context.annotation.Configuration;
  17 +import org.springframework.context.annotation.Lazy;
17 18 import org.springframework.http.converter.HttpMessageConverter;
18 19 import org.springframework.http.converter.json.MappingJackson2HttpMessageConverter;
19 20 import org.springframework.web.cors.CorsConfiguration;
... ... @@ -127,6 +128,7 @@ public class WebMvcConfiguration implements WebMvcConfigurer {
127 128 * 解决springboot2.6
128 129 * 解决metrics端点不显示jvm信息的问题(zyf)
129 130 */
  131 + @Lazy
130 132 @Bean
131 133 InitializingBean forcePrometheusPostProcessor(BeanPostProcessor meterRegistryPostProcessor, PrometheusMeterRegistry registry) {
132 134 return () -> meterRegistryPostProcessor.postProcessAfterInitialization(registry, "");
... ...