[
https://issues.apache.org/jira/browse/HADOOP-7001?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12921133#action_12921133
]
Patrick Kling commented on HADOOP-7001:
---------------------------------------
org.apache.hadoop.conf
Interface Reconfigurable
All Superinterfaces:
Configurable
___________________________________________________________________________________________________________________________________________
public interface Reconfigurable
extends Configurable
Something whose Configuration can be changed at run time.
___________________________________________________________________________________________________________________________________________
Method Summary
void changeConf(Configuration conf)
changes the configuration to the configuration passed if it is not
possible to change a configuration option a ConfigurationException is
thrown and no changes are made to the current configuration
Methods inherited from interface org.apache.hadoop.conf.Configurable
getConf, setConf
Method Detail
changeConf
void changeConf(Configuration conf)
throws ConfigurationChangeException
changes the configuration to the configuration passed if it is not
possible to change a configuration option a ConfigurationException is thrown
and no changes are made to the current configuration
Throws:
ConfigurationChangeException
Class ConfigurationChangeException
java.lang.Object
extended by java.lang.Throwable
extended by java.lang.Exception
extended by org.apache.hadoop.conf.ConfigurationChangeException
All Implemented Interfaces:
Serializable
___________________________________________________________________________________________________________________________________________
public class ConfigurationChangeException
extends Exception
exception indicating that configuration property cannot be changed at run
time
See Also:
Serialized Form
___________________________________________________________________________________________________________________________________________
Constructor Summary
ConfigurationChangeException(String property)
Creates a new instance of ConfigurationChangeException
ConfigurationChangeException(String property, String newVal)
Creates a new instance of ConfigurationChangeException
ConfigurationChangeException(String property, String newVal, String oldVal)
Creates a new instance of ConfigurationChangeException
Method Summary
String getMessage()
gets message describing exception
String getNewValue()
gets value to which property was supposed to be changed
String getOldValue()
gets old value of property that cannot be changed
String getProperty()
gets property that cannot be changed
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause,
printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait,
wait
Constructor Detail
ConfigurationChangeException
public ConfigurationChangeException(String property,
String newVal,
String oldVal)
Creates a new instance of ConfigurationChangeException
___________________________________________________________________________________________________________________________________________
ConfigurationChangeException
public ConfigurationChangeException(String property,
String newVal)
Creates a new instance of ConfigurationChangeException
___________________________________________________________________________________________________________________________________________
ConfigurationChangeException
public ConfigurationChangeException(String property)
Creates a new instance of ConfigurationChangeException
getProperty
public String getProperty()
gets property that cannot be changed
___________________________________________________________________________________________________________________________________________
getNewValue
public String getNewValue()
gets value to which property was supposed to be changed
___________________________________________________________________________________________________________________________________________
getOldValue
public String getOldValue()
gets old value of property that cannot be changed
___________________________________________________________________________________________________________________________________________
getMessage
public String getMessage()
gets message describing exception
Overrides:
getMessage in class Throwable
> Allow configuration changes without restarting configured nodes
> ---------------------------------------------------------------
>
> Key: HADOOP-7001
> URL: https://issues.apache.org/jira/browse/HADOOP-7001
> Project: Hadoop Common
> Issue Type: Task
> Reporter: Patrick Kling
>
> Currently, changing the configuration on a node (e.g., the name node)
> requires that we restart the node. We propose a change that would allow us to
> make configuration changes without restarting. Nodes that support
> configuration changes at run time should implement the following interface:
> interface ChangeableConfigured extends Configured {
> void changeConfiguration(Configuration newConf) throws
> ConfigurationChangeException;
> }
> The contract of changeConfiguration is as follows:
> The node will compare newConf to the existing configuration. For each
> configuration property that is set to a different value than in the current
> configuration, the node will either adjust its behaviour to conform to the
> new configuration or throw a ConfigurationChangeException if this change is
> not possible at run time. If a configuration property is set in the current
> configuration but is unset in newConf, the node should use its default value
> for this property. After a successful invocation of changeConfiguration, the
> behaviour of the configured node should be indistinguishable from the
> behaviour of a node that was configured with newConf at creation.
> It should be easy to change existing nodes to implement this interface. We
> can start by throwing the exception for all changes and then gradually start
> supporting more and more changes at run time. (We might even consider
> replacing Configured with ChangeableConfigured entirely, but I think the
> proposal above afford greater flexibility).
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.