From ba78f745645e6171b8df96acc76ceafb524c3857 Mon Sep 17 00:00:00 2001 From: Haotian Zhang <928016560@qq.com> Date: Tue, 10 Dec 2024 19:48:23 +0800 Subject: [PATCH] refactor:update registry status. --- .../config/extend/tsf/TsfCoreEnvironmentPostProcessor.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/spring-cloud-tencent-polaris-context/src/main/java/com/tencent/cloud/polaris/context/config/extend/tsf/TsfCoreEnvironmentPostProcessor.java b/spring-cloud-tencent-polaris-context/src/main/java/com/tencent/cloud/polaris/context/config/extend/tsf/TsfCoreEnvironmentPostProcessor.java index 54b70c54c..484be810f 100644 --- a/spring-cloud-tencent-polaris-context/src/main/java/com/tencent/cloud/polaris/context/config/extend/tsf/TsfCoreEnvironmentPostProcessor.java +++ b/spring-cloud-tencent-polaris-context/src/main/java/com/tencent/cloud/polaris/context/config/extend/tsf/TsfCoreEnvironmentPostProcessor.java @@ -129,6 +129,10 @@ public void postProcessEnvironment(ConfigurableEnvironment environment, SpringAp defaultProperties.put("spring.cloud.polaris.discovery.zero-protection.enabled", "true"); defaultProperties.put("spring.cloud.polaris.discovery.zero-protection.is-need-test-connectivity", "true"); defaultProperties.put("spring.cloud.discovery.client.health-indicator.enabled", "false"); + String warmupEnabled = environment.getProperty("spring.cloud.polaris.warmup.enabled"); + if (StringUtils.isBlank(warmupEnabled)) { + defaultProperties.put("spring.cloud.polaris.warmup.enabled", true); + } // contract defaultProperties.put("spring.cloud.polaris.contract.enabled", environment.getProperty("tsf.swagger.enabled", "true"));