public class NacosRegistration extends Object implements org.springframework.cloud.client.serviceregistry.Registration, org.springframework.cloud.client.ServiceInstance
| Modifier and Type | Field and Description |
|---|---|
static String |
MANAGEMENT_ADDRESS
The metadata key of management address.
|
static String |
MANAGEMENT_CONTEXT_PATH
The metadata key of management context-path.
|
static String |
MANAGEMENT_ENDPOINT_BASE_PATH
The metadata key of management endpoints web base path.
|
static String |
MANAGEMENT_PORT
The metadata key of management port.
|
| Constructor and Description |
|---|
NacosRegistration(List<NacosRegistrationCustomizer> registrationCustomizers,
NacosDiscoveryProperties nacosDiscoveryProperties,
org.springframework.context.ApplicationContext context) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
customize(List<NacosRegistrationCustomizer> registrationCustomizers) |
String |
getCluster() |
String |
getHost() |
Map<String,String> |
getMetadata() |
NacosDiscoveryProperties |
getNacosDiscoveryProperties() |
int |
getPort() |
float |
getRegisterWeight() |
String |
getServiceId() |
URI |
getUri() |
void |
init() |
boolean |
isRegisterEnabled() |
boolean |
isSecure() |
void |
setPort(int port) |
String |
toString() |
public static final String MANAGEMENT_PORT
public static final String MANAGEMENT_CONTEXT_PATH
public static final String MANAGEMENT_ADDRESS
public static final String MANAGEMENT_ENDPOINT_BASE_PATH
public NacosRegistration(List<NacosRegistrationCustomizer> registrationCustomizers, NacosDiscoveryProperties nacosDiscoveryProperties, org.springframework.context.ApplicationContext context)
@PostConstruct public void init()
protected void customize(List<NacosRegistrationCustomizer> registrationCustomizers)
public String getServiceId()
getServiceId in interface org.springframework.cloud.client.ServiceInstancepublic String getHost()
getHost in interface org.springframework.cloud.client.ServiceInstancepublic int getPort()
getPort in interface org.springframework.cloud.client.ServiceInstancepublic void setPort(int port)
public boolean isSecure()
isSecure in interface org.springframework.cloud.client.ServiceInstancepublic URI getUri()
getUri in interface org.springframework.cloud.client.ServiceInstancepublic Map<String,String> getMetadata()
getMetadata in interface org.springframework.cloud.client.ServiceInstancepublic boolean isRegisterEnabled()
public String getCluster()
public float getRegisterWeight()
public NacosDiscoveryProperties getNacosDiscoveryProperties()
Copyright © 2022 Pivotal Software, Inc.. All rights reserved.