public class ConsulDynamicConfiguration extends Object implements DynamicConfiguration
DEFAULT_GROUP| Constructor and Description |
|---|
ConsulDynamicConfiguration(URL url) |
| Modifier and Type | Method and Description |
|---|---|
void |
addListener(String key,
String group,
ConfigurationListener listener) |
void |
close() |
String |
getConfig(String key,
String group,
long timeout) |
SortedSet<String> |
getConfigKeys(String group) |
Object |
getInternalProperty(String key) |
boolean |
publishConfig(String key,
String group,
String content) |
void |
removeListener(String key,
String group,
ConfigurationListener listener) |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddListener, getConfig, getDefaultGroup, getDefaultTimeout, getDynamicConfiguration, getDynamicConfiguration, getProperties, getProperties, getRuleKey, publishConfig, removeListenercontainsKey, convert, getBoolean, getBoolean, getBoolean, getInt, getInt, getInteger, getProperty, getProperty, getString, getString, toBooleanObjectpublic ConsulDynamicConfiguration(URL url)
public void addListener(String key, String group, ConfigurationListener listener)
addListener in interface DynamicConfigurationpublic void removeListener(String key, String group, ConfigurationListener listener)
removeListener in interface DynamicConfigurationpublic String getConfig(String key, String group, long timeout) throws IllegalStateException
getConfig in interface DynamicConfigurationIllegalStateExceptionpublic SortedSet<String> getConfigKeys(String group) throws UnsupportedOperationException
getConfigKeys in interface DynamicConfigurationUnsupportedOperationExceptionpublic boolean publishConfig(String key, String group, String content) throws UnsupportedOperationException
publishConfig in interface DynamicConfigurationkey - the key to represent a configurationgroup - the group where the key belongs tocontent - the content of configurationUnsupportedOperationExceptionpublic Object getInternalProperty(String key)
getInternalProperty in interface Configurationpublic void close()
throws Exception
close in interface AutoCloseableclose in interface DynamicConfigurationExceptionCopyright © 2011–2020 The Apache Software Foundation. All rights reserved.