Return-Path: Delivered-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Received: (qmail 39188 invoked from network); 2 Jun 2010 17:31:59 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 2 Jun 2010 17:31:59 -0000 Received: (qmail 61530 invoked by uid 500); 2 Jun 2010 17:31:59 -0000 Delivered-To: apmail-hadoop-common-issues-archive@hadoop.apache.org Received: (qmail 61412 invoked by uid 500); 2 Jun 2010 17:31:58 -0000 Mailing-List: contact common-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-issues@hadoop.apache.org Delivered-To: mailing list common-issues@hadoop.apache.org Received: (qmail 61404 invoked by uid 99); 2 Jun 2010 17:31:58 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Jun 2010 17:31:58 +0000 X-ASF-Spam-Status: No, hits=-1490.6 required=10.0 tests=ALL_TRUSTED,AWL 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; Wed, 02 Jun 2010 17:31:58 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o52HVbOj011957 for ; Wed, 2 Jun 2010 17:31:38 GMT Message-ID: <16550780.137581275499897405.JavaMail.jira@thor> Date: Wed, 2 Jun 2010 13:31:37 -0400 (EDT) From: "Konstantin Boudnik (JIRA)" To: common-issues@hadoop.apache.org Subject: [jira] Commented: (HADOOP-6788) [Herriot] Exception exclusion functionality is not working correctly. 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/HADOOP-6788?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12874686#action_12874686 ] Konstantin Boudnik commented on HADOOP-6788: -------------------------------------------- bq. Can you please augment the title of all future herriot related issues with [Herriot]? Well, I'm not sure about this. Herriot never was approved/discussed by the community as an official name of the framework. Let's think about this first. > [Herriot] Exception exclusion functionality is not working correctly. > --------------------------------------------------------------------- > > Key: HADOOP-6788 > URL: https://issues.apache.org/jira/browse/HADOOP-6788 > Project: Hadoop Common > Issue Type: Bug > Components: test > Affects Versions: 0.21.0 > Reporter: Vinay Kumar Thota > Assignee: Balaji Rajagopalan > Attachments: 6788-ydist-security.patch, 6788-ydist-security.patch, HADOOP-6788.patch, HADOOP-6788.patch > > > Exception exclusion functionality is not working correctly because of that tests are failing by not matching the error count. > I debugged the issue and found that the problem with shell command which is generating in the getNumberOfMatchesInLogFile function. > Currently building the shell command in the following way. > if(list != null){ > for(int i =0; i < list.length; ++i) > { > filePattern.append(" | grep -v " + list[i] ); > } > } > String[] cmd = > new String[] { > "bash", > "-c", > "grep -c " > + pattern + " " + filePattern > + " | awk -F: '{s+=$2} END {print s}'" }; > However, The above commnad won't work correctly because you are counting the exceptions in the file before excluding the known exceptions. > In this case it gives the mismatch error counts everytime.The shell command should be in the following way to work correctly. > if (list != null) { > int index = 0; > for (String excludeExp : list) { > filePattern.append((++index < list.length)? "| grep -v " : > "| grep -vc " + list[i] ); > } > } > String[] cmd = > new String[] { > "bash", > "-c", > "grep " > + pattern + " " + filePattern > + " | awk -F: '{s+=$2} END {print s}'" }; -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.