Return-Path: Delivered-To: apmail-hadoop-core-dev-archive@www.apache.org Received: (qmail 54401 invoked from network); 28 Aug 2008 17:53:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 28 Aug 2008 17:53:37 -0000 Received: (qmail 33707 invoked by uid 500); 28 Aug 2008 17:53:33 -0000 Delivered-To: apmail-hadoop-core-dev-archive@hadoop.apache.org Received: (qmail 33681 invoked by uid 500); 28 Aug 2008 17:53:33 -0000 Mailing-List: contact core-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: core-dev@hadoop.apache.org Delivered-To: mailing list core-dev@hadoop.apache.org Received: (qmail 33670 invoked by uid 99); 28 Aug 2008 17:53:33 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Aug 2008 10:53:33 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Aug 2008 17:52:44 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 6D3DE234C1C7 for ; Thu, 28 Aug 2008 10:52:44 -0700 (PDT) Message-ID: <589157346.1219945964444.JavaMail.jira@brutus> Date: Thu, 28 Aug 2008 10:52:44 -0700 (PDT) From: "Ryan Smith (JIRA)" To: core-dev@hadoop.apache.org Subject: [jira] Commented: (HADOOP-2866) JobConf should validate key names in well-defined namespaces and warn on misspelling In-Reply-To: <389151326.1203567223364.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HADOOP-2866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12626670#action_12626670 ] Ryan Smith commented on HADOOP-2866: ------------------------------------ +1 Instead of using : jobConf.set(String key,String value) I vote for using getters/setters (spring configurable) to pass just the value: jobConf.setSomeProperty(String value) And using constructors to instantiate objects (or at least offer it as an option). Off hand, i know DistributedFileSystem() could benefit from a 2 arg constructor that calls initialize(arg1,arg2) so DI frameworks like spring are supported. I would be interested in submitting a patch soon for some of these config access issues on a one or two other classes. Ill add the patch here or start a new issue for it, please let me know. Thanks, -Ryan > JobConf should validate key names in well-defined namespaces and warn on misspelling > ------------------------------------------------------------------------------------ > > Key: HADOOP-2866 > URL: https://issues.apache.org/jira/browse/HADOOP-2866 > Project: Hadoop Core > Issue Type: Improvement > Components: mapred > Affects Versions: 0.16.0 > Reporter: Aaron Kimball > Priority: Minor > Original Estimate: 72h > Remaining Estimate: 72h > > A discussion on the mailing list reveals that some configuration strings in the JobConf are deprecated over time and new configuration names replace them: > e.g., "mapred.output.compression.type" is now replaced with "mapred.map.output.compression.type" > Programmers who have been manually specifying the former string, however, receive no diagnostic output during testing to suggest that their compression type is being silently ignored. > It would be desirable to notify developers of this change by printing a warning message when deprecated configuration names are used in a newer version of Hadoop. More generally, when any configuration string in the mapred.\*, fs.\*, dfs.\*, etc namespaces are provided by a user and are not recognized by Hadoop, it is desirable to print a warning, to indicate malformed configurations. No warnings should be printed when configuration keys are in user-defined namespaces (e.g., "myprogram.mytask.myvalue"). -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.