From hdfs-issues-return-255345-archive-asf-public=cust-asf.ponee.io@hadoop.apache.org Thu Mar 7 08:09:13 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 11CE518067E for ; Thu, 7 Mar 2019 09:09:12 +0100 (CET) Received: (qmail 25278 invoked by uid 500); 7 Mar 2019 08:09:11 -0000 Mailing-List: contact hdfs-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list hdfs-issues@hadoop.apache.org Received: (qmail 25247 invoked by uid 99); 7 Mar 2019 08:09:11 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Mar 2019 08:09:11 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 0BCA4C039B for ; Thu, 7 Mar 2019 08:09:11 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -110.301 X-Spam-Level: X-Spam-Status: No, score=-110.301 tagged_above=-999 required=6.31 tests=[ENV_AND_HDR_SPF_MATCH=-0.5, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001, USER_IN_DEF_SPF_WL=-7.5, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id U9RbapeyXMfE for ; Thu, 7 Mar 2019 08:09:09 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 335C060DC2 for ; Thu, 7 Mar 2019 08:02:01 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 53747E277B for ; Thu, 7 Mar 2019 08:02:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 0DE102576E for ; Thu, 7 Mar 2019 08:02:00 +0000 (UTC) Date: Thu, 7 Mar 2019 08:02:00 +0000 (UTC) From: "Anuhan Torgonshar (JIRA)" To: hdfs-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HDFS-14340) Lower the log level when can't get postOpAttr MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HDFS-14340?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:all-tabpanel ] Anuhan Torgonshar updated HDFS-14340: ------------------------------------- Status: Open (was: Patch Available) > Lower the log level when can't get postOpAttr > --------------------------------------------- > > Key: HDFS-14340 > URL: https://issues.apache.org/jira/browse/HDFS-14340 > Project: Hadoop HDFS > Issue Type: Improvement > Components: nfs > Affects Versions: 2.8.5, 3.1.0 > Reporter: Anuhan Torgonshar > Priority: Major > Labels: easyfix > Attachments: HDFS-14340.patch > > > I think should lower the log level when can't get postOpAttr in=C2=A0_*ha= doop-2.8.5-src/hadoop-hdfs-project/hadoop-hdfs-nfs/src/main/java/org/apache= /hadoop/hdfs/nfs/nfs3/**RpcProgramNfs3.java*_.=C2=A0 > =C2=A0 > {code:java} > **************The fisrt code snippet*************** > //the problematic log level ERROR, at line 1044 > try { > dirWcc =3D Nfs3Utils.createWccData(Nfs3Utils.getWccAttr(preOpDirAttr), > dfsClient, dirFileIdPath, iug); > } catch (IOException e1) { > LOG.error("Can't get postOpDirAttr for dirFileId: " > + dirHandle.getFileId(), e1); > } > **************The second code snippet*************** > //other practice in similar code snippets, line number is 475, the log as= signed with INFO level > try {=20 > wccData =3D Nfs3Utils.createWccData(Nfs3Utils.getWccAttr(preOpAttr), d= fsClient, fileIdPath, iug);=20 > } catch (IOException e1) {=20 > LOG.info("Can't get postOpAttr for fileIdPath: " + fileIdPath, e1);=20 > } > **************The third code snippet*************** > //other practice in similar code snippets, line number is 1405, the log a= ssigned with INFO level > try { > fromDirWcc =3D Nfs3Utils.createWccData( > Nfs3Utils.getWccAttr(fromPreOpAttr), dfsClient, fromDirFileIdPath,iug)= ; > toDirWcc =3D Nfs3Utils.createWccData(Nfs3Utils.getWccAttr(toPreOpAttr)= , > dfsClient, toDirFileIdPath, iug); > } catch (IOException e1) { > LOG.info("Can't get postOpDirAttr for " + fromDirFileIdPath + " or" > + toDirFileIdPath, e1); > } > {code} > Therefore, I think the logging practices should be consistent in similar = contexts. When the code catches _*IOException*_ for *_getWccAttr()_* method= , it more likely prints a log message with _*INFO*_ level, a lower level. > =C2=A0 -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscribe@hadoop.apache.org For additional commands, e-mail: hdfs-issues-help@hadoop.apache.org