You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by Jason Lowe <jl...@yahoo-inc.com> on 2013/07/02 16:34:43 UTC
Configuration and final parameters
Someone in our group recently discovered that Configuration parameters
marked final can still be set(). The final designation only seems to be
important when loading resources and is ignored when individual
properties are modified. The javadocs do call out loaded resources
explicitly, but there's no indication as to why final properties are not
checked during individual property modifications. Bug or intentional?
Will something break if it calls set() and subsequently doesn't see the
updated value because the final parameter silently ignored the new setting?
The lack of checks in the set methods appear to be an oversight, but
maybe I'm missing a use case?
Jason
Re: Configuration and final parameters
Posted by Jason Lowe <jl...@yahoo-inc.com>.
Given the lack of feedback, I'm guessing this is just a bug. Filed
HADOOP-9725.
On 07/02/2013 09:34 AM, Jason Lowe wrote:
> Someone in our group recently discovered that Configuration parameters
> marked final can still be set(). The final designation only seems to
> be important when loading resources and is ignored when individual
> properties are modified. The javadocs do call out loaded resources
> explicitly, but there's no indication as to why final properties are
> not checked during individual property modifications. Bug or
> intentional? Will something break if it calls set() and subsequently
> doesn't see the updated value because the final parameter silently
> ignored the new setting?
>
> The lack of checks in the set methods appear to be an oversight, but
> maybe I'm missing a use case?
>
> Jason
>