[ 
https://issues.apache.org/jira/browse/HADOOP-11302?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14214302#comment-14214302
 ] 

Kannan Rajah commented on HADOOP-11302:
---------------------------------------

Thanks for providing the background. But there is one thing I still don't 
understand. Let's say admin has created an XML file with some final properties 
to make sure that it does not get overridden. Now, what is the difference 
between a user loading his version of XML file by adding it as a resource and 
instead just programmatically overriding all properties using the set method? 
It seems like we are trying to protect against the first case and not the 
second case. That is why I thought this needed to be fixed.

> Configuration#set method should honor final properties
> ------------------------------------------------------
>
>                 Key: HADOOP-11302
>                 URL: https://issues.apache.org/jira/browse/HADOOP-11302
>             Project: Hadoop Common
>          Issue Type: Bug
>    Affects Versions: 2.5.1
>            Reporter: Kannan Rajah
>            Assignee: Kannan Rajah
>         Attachments: final-properties.patch
>
>
> Configuration class has several methods to add a configuration resource. The
> properties of this resource can override properties of previously added
> resources, unless they were marked final. According to the Javadoc for 
> Configuration.java, the check for final properties is done
> only while loading resources. But it makes sense to do this check in the set 
> API as well. Otherwise, users will be able to override final properties set 
> by admin.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to