Return-Path: X-Original-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Delivered-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5D63018FD4 for ; Mon, 18 Jan 2016 02:02:40 +0000 (UTC) Received: (qmail 49411 invoked by uid 500); 18 Jan 2016 02:02:40 -0000 Delivered-To: apmail-hadoop-common-issues-archive@hadoop.apache.org Received: (qmail 49361 invoked by uid 500); 18 Jan 2016 02:02:40 -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 49350 invoked by uid 99); 18 Jan 2016 02:02:40 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 18 Jan 2016 02:02:40 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id E5FC22C0453 for ; Mon, 18 Jan 2016 02:02:39 +0000 (UTC) Date: Mon, 18 Jan 2016 02:02:39 +0000 (UTC) From: "Vikram Srivastava (JIRA)" To: common-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HADOOP-12702) Add an HDFS metrics sink 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-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15104060#comment-15104060 ] Vikram Srivastava commented on HADOOP-12702: -------------------------------------------- FileSystem.create(Path) will delete any existing file (line 108). I think we should check if a file already exists and in that case append to it instead of overwriting it. > Add an HDFS metrics sink > ------------------------ > > Key: HADOOP-12702 > URL: https://issues.apache.org/jira/browse/HADOOP-12702 > Project: Hadoop Common > Issue Type: Improvement > Components: metrics > Affects Versions: 2.7.1 > Reporter: Daniel Templeton > Assignee: Daniel Templeton > Attachments: HADOOP-12702.001.patch > > > We need a metrics2 sink that can write metrics to HDFS. The sink should accept as configuration a "directory prefix" and do the following in {{putMetrics()}} > * Get yyyyMMddHH from current timestamp. > * If HDFS dir "dir prefix" + yyyyMMddHH doesn't exist, create it. Close any currently open file and create a new file called .log in the new directory. > * Write metrics to the current log file. > * If a write fails, it should be fatal to the process running the sink. -- This message was sent by Atlassian JIRA (v6.3.4#6332)