public class FileSystemDynamicConfiguration extends AbstractDynamicConfiguration
DynamicConfiguration implementation| Modifier and Type | Field and Description |
|---|---|
static String |
CONFIG_CENTER_DIR_PARAM_NAME |
static String |
CONFIG_CENTER_ENCODING_PARAM_NAME |
static String |
DEFAULT_CONFIG_CENTER_DIR_PATH |
static String |
DEFAULT_CONFIG_CENTER_ENCODING |
static int |
DEFAULT_THREAD_POOL_SIZE |
DEFAULT_THREAD_POOL_KEEP_ALIVE_TIME, DEFAULT_THREAD_POOL_PREFIX, PARAM_NAME_PREFIX, THREAD_POOL_KEEP_ALIVE_TIME_PARAM_NAME, THREAD_POOL_PREFIX_PARAM_NAME, THREAD_POOL_SIZE_PARAM_NAMEDEFAULT_GROUP| Constructor and Description |
|---|
FileSystemDynamicConfiguration() |
FileSystemDynamicConfiguration(File rootDirectory) |
FileSystemDynamicConfiguration(File rootDirectory,
String encoding) |
FileSystemDynamicConfiguration(File rootDirectory,
String encoding,
String threadPoolPrefixName) |
FileSystemDynamicConfiguration(File rootDirectory,
String encoding,
String threadPoolPrefixName,
int threadPoolSize) |
FileSystemDynamicConfiguration(File rootDirectory,
String encoding,
String threadPoolPrefixName,
int threadPoolSize,
long keepAliveTime) |
FileSystemDynamicConfiguration(URL url) |
| Modifier and Type | Method and Description |
|---|---|
void |
addListener(String key,
String group,
ConfigurationListener listener)
Register a configuration listener for a specified key
The listener only works for service governance purpose, so the target group would always be the value user
specifies at startup or 'dubbo' by default.
|
File |
configFile(String key,
String group) |
Set<String> |
getConfigGroups() |
SortedSet<String> |
getConfigKeys(String group)
Get the config keys by the specified group
|
String |
getEncoding() |
Object |
getInternalProperty(String key) |
File |
getRootDirectory() |
File |
groupDirectory(String group) |
boolean |
publishConfig(String key,
String group,
String content)
Publish Config mapped to the given key and the given group.
|
String |
removeConfig(String key,
String group) |
void |
removeListener(String key,
String group,
ConfigurationListener listener)
Stops one listener from listening to value changes in the specified key.
|
close, getConfigequals, 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 static final String CONFIG_CENTER_DIR_PARAM_NAME
public static final String CONFIG_CENTER_ENCODING_PARAM_NAME
public static final String DEFAULT_CONFIG_CENTER_DIR_PATH
public static final int DEFAULT_THREAD_POOL_SIZE
public static final String DEFAULT_CONFIG_CENTER_ENCODING
public FileSystemDynamicConfiguration()
public FileSystemDynamicConfiguration(File rootDirectory)
public FileSystemDynamicConfiguration(File rootDirectory, String encoding)
public FileSystemDynamicConfiguration(File rootDirectory, String encoding, String threadPoolPrefixName)
public FileSystemDynamicConfiguration(File rootDirectory, String encoding, String threadPoolPrefixName, int threadPoolSize)
public FileSystemDynamicConfiguration(File rootDirectory, String encoding, String threadPoolPrefixName, int threadPoolSize, long keepAliveTime)
public FileSystemDynamicConfiguration(URL url)
public void addListener(String key, String group, ConfigurationListener listener)
DynamicConfigurationaddListener in interface DynamicConfigurationaddListener in class AbstractDynamicConfigurationkey - the key to represent a configurationgroup - the group where the key belongs tolistener - configuration listenerpublic void removeListener(String key, String group, ConfigurationListener listener)
DynamicConfigurationremoveListener in interface DynamicConfigurationremoveListener in class AbstractDynamicConfigurationkey - the key to represent a configurationgroup - the group where the key belongs tolistener - configuration listenerpublic Object getInternalProperty(String key)
getInternalProperty in interface ConfigurationgetInternalProperty in class AbstractDynamicConfigurationpublic boolean publishConfig(String key, String group, String content)
DynamicConfigurationkey - the key to represent a configurationgroup - the group where the key belongs tocontent - the content of configurationtrue if success, or falsepublic SortedSet<String> getConfigKeys(String group)
DynamicConfigurationgroup - the specified groupset of config keyspublic File getRootDirectory()
public String getEncoding()
Copyright © 2011–2020 The Apache Software Foundation. All rights reserved.