From common-issues-return-159407-archive-asf-public=cust-asf.ponee.io@hadoop.apache.org Thu Oct 11 23:47:03 2018 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 34DE118067A for ; Thu, 11 Oct 2018 23:47:03 +0200 (CEST) Received: (qmail 55066 invoked by uid 500); 11 Oct 2018 21:47:02 -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 55055 invoked by uid 99); 11 Oct 2018 21:47:02 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 11 Oct 2018 21:47:02 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id B82E6182338 for ; Thu, 11 Oct 2018 21:47:01 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-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-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id EphVF5fK11Vw for ; Thu, 11 Oct 2018 21:47:00 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id B1CEF5F1EA for ; Thu, 11 Oct 2018 21:47:00 +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 54CD2E0179 for ; Thu, 11 Oct 2018 21:47: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 21BFD2486A for ; Thu, 11 Oct 2018 21:47:00 +0000 (UTC) Date: Thu, 11 Oct 2018 21:47:00 +0000 (UTC) From: "Xiao Chen (JIRA)" To: common-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HADOOP-15717) TGT renewal thread does not log IOException 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-15717?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16647068#comment-16647068 ] Xiao Chen commented on HADOOP-15717: ------------------------------------ Thanks for the discussion [~rkanter] and [~snemeth]. https://www.slf4j.org/apidocs/org/slf4j/Logger.html has a dedicated section for this actually. :) {quote} Be sure to read the FAQ entry relating to parameterized logging. Note that logging statements can be parameterized in presence of an exception/throwable. {quote} which links to https://www.slf4j.org/faq.html#paramException . I also confirmed with {{TestUGI#testKerberosTicketIsDestroyedChecked}} that the behavior is the same. But as the slf4j page explains, this behavior is post slf4j 1.6.0, I think it's probably a good idea to commit the patch as-is, so we don't change behavior based on slf4j's version. +1 on patch 2 from me. > TGT renewal thread does not log IOException > ------------------------------------------- > > Key: HADOOP-15717 > URL: https://issues.apache.org/jira/browse/HADOOP-15717 > Project: Hadoop Common > Issue Type: Improvement > Reporter: Szilard Nemeth > Assignee: Szilard Nemeth > Priority: Major > Attachments: HADOOP-15717.001.patch, HADOOP-15717.002.patch > > > I came across a case where tgt.getEndTime() was returned null and it resulted in an NPE, this observation was popped out of a test suite execution on a cluster. The reason for logging the {{IOException}} is that it helps to troubleshoot what caused the exception, as it can come from two different calls from the try-catch. > I can see that [~gabor.bota] handled this with HADOOP-15593, but apart from logging the fact that the ticket's {{endDate}} was null, we have not logged the exception at all. > With the current code, the exception is swallowed and the thread terminates in case the ticket's {{endDate}} is null. > As this can happen with OpenJDK for example, it is required to print the exception (stack trace, message) to the log. > The code should be updated here: https://github.com/apache/hadoop/blob/trunk/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/UserGroupInformation.java#L918 -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org For additional commands, e-mail: common-issues-help@hadoop.apache.org