优化,使用 @Configuration(proxyBeanMethods = false) 提升启动速度

This commit is contained in:
YunaiV
2022-11-12 20:27:51 +08:00
parent d87343d70c
commit bb2303e789
42 changed files with 42 additions and 43 deletions

View File

@@ -36,7 +36,7 @@ import org.springframework.integration.config.GlobalChannelInterceptor;
import java.util.Objects;
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnProperty(prefix = "yudao.tenant", value = "enable", matchIfMissing = true) // 允许使用 yudao.tenant.enable=false 禁用多租户
@EnableConfigurationProperties(TenantProperties.class)
public class YudaoTenantAutoConfiguration {

View File

@@ -8,7 +8,7 @@ import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnProperty(prefix = "yudao.tenant", value = "enable", matchIfMissing = true) // 允许使用 yudao.tenant.enable=false 禁用多租户
@EnableFeignClients(clients = TenantApi.class) // 主要是引入相关的 API 服务
public class YudaoTenantRpcAutoConfiguration {