@Configuration(proxyBeanMethods=false)
@ConditionalOnDiscoveryEnabled
@ConditionalOnBlockingDiscoveryEnabled
@AutoConfigureBefore(value={org.springframework.cloud.client.discovery.simple.SimpleDiscoveryClientAutoConfiguration.class,org.springframework.cloud.client.CommonsClientAutoConfiguration.class})
@AutoConfigureAfter(value=NacosDiscoveryAutoConfiguration.class)
public class NacosDiscoveryClientConfiguration
extends Object
| Constructor and Description |
|---|
NacosDiscoveryClientConfiguration() |
| Modifier and Type | Method and Description |
|---|---|
GatewayLocatorHeartBeatPublisher |
gatewayLocatorHeartBeatPublisher(NacosDiscoveryProperties nacosDiscoveryProperties)
Spring Cloud Gateway HeartBeat .
|
org.springframework.cloud.client.discovery.DiscoveryClient |
nacosDiscoveryClient(NacosServiceDiscovery nacosServiceDiscovery) |
NacosWatch |
nacosWatch(NacosServiceManager nacosServiceManager,
NacosDiscoveryProperties nacosDiscoveryProperties)
NacosWatch is no longer enabled by default .
|
@Bean public org.springframework.cloud.client.discovery.DiscoveryClient nacosDiscoveryClient(NacosServiceDiscovery nacosServiceDiscovery)
@Bean
@ConditionalOnMissingBean
@ConditionalOnProperty(value="spring.cloud.nacos.discovery.watch.enabled",
matchIfMissing=false)
public NacosWatch nacosWatch(NacosServiceManager nacosServiceManager,
NacosDiscoveryProperties nacosDiscoveryProperties)
@Bean
@ConditionalOnMissingBean
@ConditionalOnProperty(value="spring.cloud.gateway.discovery.locator.enabled",
matchIfMissing=false)
public GatewayLocatorHeartBeatPublisher gatewayLocatorHeartBeatPublisher(NacosDiscoveryProperties nacosDiscoveryProperties)
Copyright © 2023 Pivotal Software, Inc.. All rights reserved.