public class ConfigurationService extends Object implements Service, Instrumentable
OOZIE_HOME environment variable as
${OOZIE_HOME}/conf. If the OOZIE_HOME environment variable is not defined the
initialization of the ConfigurationService fails.
The site configuration is loaded from the oozie-site.xml file in the configuration directory.
The site configuration file name to use can be changed by setting the OOZIE_CONFIG_FILE environment
variable to an alternate file name. The alternate file must ber in the Oozie configuration directory.
Configuration properties, prefixed with 'oozie.', passed as system properties overrides default and site values.
The configuration service logs details on how the configuration was loaded as well as what properties were overrode
via system properties settings.| Modifier and Type | Field and Description |
|---|---|
static String |
CONF_IGNORE_SYS_PROPS |
static String |
CONF_PREFIX |
static String |
DEFAULT_CONFIG_FILE |
static String |
OOZIE_CONFIG_DIR
System property that indicates the configuration directory.
|
static String |
OOZIE_CONFIG_FILE
System property that indicates the name of the site configuration file to load.
|
static String |
OOZIE_DATA_DIR
System property that indicates the data directory.
|
static String |
SITE_CONFIG_FILE |
DEFAULT_LOCK_TIMEOUT, lockTimeout, USE_XCOMMAND| Constructor and Description |
|---|
ConfigurationService() |
| Modifier and Type | Method and Description |
|---|---|
void |
destroy()
Destroy the configuration service.
|
org.apache.hadoop.conf.Configuration |
getConf()
Return the services configuration.
|
String |
getConfigDir()
Return Oozie configuration directory.
|
static String |
getConfigurationDirectory() |
Class<? extends Service> |
getInterface()
Return the public interface for configuration service.
|
org.apache.hadoop.conf.Configuration |
getMaskedConfiguration()
Return a configuration with all sensitive values masked.
|
void |
init(Services services)
Initialize the log service.
|
void |
instrument(Instrumentation instr)
Instruments the configuration service.
|
public static final String CONF_PREFIX
public static final String CONF_IGNORE_SYS_PROPS
public static final String OOZIE_CONFIG_DIR
public static final String OOZIE_DATA_DIR
public static final String OOZIE_CONFIG_FILE
public static final String DEFAULT_CONFIG_FILE
public static final String SITE_CONFIG_FILE
public ConfigurationService()
public void init(Services services) throws ServiceException
init in interface Serviceservices - services instance.ServiceException - thrown if the log service could not be initialized.public static String getConfigurationDirectory() throws ServiceException
ServiceExceptionpublic void destroy()
public Class<? extends Service> getInterface()
getInterface in interface ServiceConfigurationService.public org.apache.hadoop.conf.Configuration getConf()
public String getConfigDir()
public void instrument(Instrumentation instr)
instrument in interface Instrumentableinstr - instrumentation to use.public org.apache.hadoop.conf.Configuration getMaskedConfiguration()
Copyright © 2014 Apache Software Foundation. All Rights Reserved.