Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id D97EF200B40 for ; Fri, 1 Jul 2016 18:36:12 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id D7FF8160A61; Fri, 1 Jul 2016 16:36:12 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 2D0A0160A4D for ; Fri, 1 Jul 2016 18:36:12 +0200 (CEST) Received: (qmail 42853 invoked by uid 500); 1 Jul 2016 16:36:11 -0000 Mailing-List: contact common-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list common-issues@hadoop.apache.org Received: (qmail 42842 invoked by uid 99); 1 Jul 2016 16:36:11 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 01 Jul 2016 16:36:11 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id F35032C02A2 for ; Fri, 1 Jul 2016 16:36:10 +0000 (UTC) Date: Fri, 1 Jul 2016 16:36:10 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: common-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HADOOP-13320) Fix arguments check in documentation for WordCount v2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 01 Jul 2016 16:36:13 -0000 [ https://issues.apache.org/jira/browse/HADOOP-13320?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15359226#comment-15359226 ] ASF GitHub Bot commented on HADOOP-13320: ----------------------------------------- Github user pippobaudos closed the pull request at: https://github.com/apache/hadoop/pull/105 > Fix arguments check in documentation for WordCount v2.0 > ------------------------------------------------------- > > Key: HADOOP-13320 > URL: https://issues.apache.org/jira/browse/HADOOP-13320 > Project: Hadoop Common > Issue Type: Bug > Components: documentation > Reporter: niccolo becchi > Priority: Trivial > > This issue is affecting the documentation page, so the code is not covered by any tests. It's actually visible on the page: > https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html#Example:_WordCount_v2.0 > On the Example: WordCount v2.0 > The actual arguments check is wrong, as it's never printing the message of the correct usage. So, running the code with no parameters, as in the following example: > {code} > yarn jar /var/tmp/WordCount.jar task0.WordCount2 > {code} > > I have got the following exception message in output: > {code} > Exception in thread "main" java.lang.IndexOutOfBoundsException: Index: 0, Size: 0 > at java.util.ArrayList.rangeCheck(ArrayList.java:635) > at java.util.ArrayList.get(ArrayList.java:411) > at task0.WordCount2.main(WordCount2.java:131) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:606) > at org.apache.hadoop.util.RunJar.run(RunJar.java:221) > at org.apache.hadoop.util.RunJar.main(RunJar.java:136) > {code} > Intead than the expected friendly message: > {code} > Usage: wordcount [-skip skipPatternFile] > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org For additional commands, e-mail: common-issues-help@hadoop.apache.org