Return-Path: Delivered-To: apmail-mahout-dev-archive@www.apache.org Received: (qmail 9563 invoked from network); 7 Jun 2010 12:19:02 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 7 Jun 2010 12:19:02 -0000 Received: (qmail 77406 invoked by uid 500); 7 Jun 2010 12:19:01 -0000 Delivered-To: apmail-mahout-dev-archive@mahout.apache.org Received: (qmail 77332 invoked by uid 500); 7 Jun 2010 12:19:01 -0000 Mailing-List: contact dev-help@mahout.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@mahout.apache.org Delivered-To: mailing list dev@mahout.apache.org Received: (qmail 77324 invoked by uid 99); 7 Jun 2010 12:19:01 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 07 Jun 2010 12:19:01 +0000 X-ASF-Spam-Status: No, hits=-1502.0 required=10.0 tests=ALL_TRUSTED,AWL,URI_HEX X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 07 Jun 2010 12:19:01 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o57CIemK012139 for ; Mon, 7 Jun 2010 12:18:41 GMT Message-ID: <30778098.911275913120634.JavaMail.jira@thor> Date: Mon, 7 Jun 2010 08:18:40 -0400 (EDT) From: "Sean Owen (JIRA)" To: dev@mahout.apache.org Subject: [jira] Commented: (MAHOUT-404) AbstractJob improvements. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/MAHOUT-404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12876222#action_12876222 ] Sean Owen commented on MAHOUT-404: ---------------------------------- Looks OK to me. As far as I'm concerned, go ahead and let me play with the result. > AbstractJob improvements. > ------------------------- > > Key: MAHOUT-404 > URL: https://issues.apache.org/jira/browse/MAHOUT-404 > Project: Mahout > Issue Type: Improvement > Components: Utils > Affects Versions: 0.4 > Reporter: Drew Farris > Attachments: MAHOUT-404.patch, MAHOUT-404.patch > > > Per discussion : http://lucene.472066.n3.nabble.com/Re-input-now-Dmapred-input-dir-td852297.html#a852297 > With the advent of the parsedArgs map returned by AbstractJob.parseArguments is there > a need to pass Option arguments around anymore? Could AbstractJob maintain > Options state in a sense? > For example, from RecommenderJob: > {code} > Option numReccomendationsOpt = AbstractJob.buildOption("numRecommendations", "n", > "Number of recommendations per user", "10"); > Option usersFileOpt = AbstractJob.buildOption("usersFile", "u", > "File of users to recommend for", null); > Option booleanDataOpt = AbstractJob.buildOption("booleanData", "b", > "Treat input as without pref values", Boolean.FALSE.toString()); > Map parsedArgs = AbstractJob.parseArguments( > args, numReccomendationsOpt, usersFileOpt, booleanDataOpt); > if (parsedArgs == null) { > return -1; > } > {code} > Could be changed to something like: > {code} > buildOption("numRecommendations", "n", "Number of recommendations per user", > "10"); > buildOption("usersFile", "u", "File of users to recommend for", null); > buildOption("booleanData", "b", "Treat input as without pref values", > Boolean.FALSE.toString()); > Map parsedArgs = parseArguments(); > {code} -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.