Return-Path: Delivered-To: apmail-hadoop-core-dev-archive@www.apache.org Received: (qmail 77296 invoked from network); 2 Jun 2008 23:22:07 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 2 Jun 2008 23:22:07 -0000 Received: (qmail 30760 invoked by uid 500); 2 Jun 2008 23:22:08 -0000 Delivered-To: apmail-hadoop-core-dev-archive@hadoop.apache.org Received: (qmail 30735 invoked by uid 500); 2 Jun 2008 23:22:08 -0000 Mailing-List: contact core-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: core-dev@hadoop.apache.org Delivered-To: mailing list core-dev@hadoop.apache.org Received: (qmail 30724 invoked by uid 99); 2 Jun 2008 23:22:08 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 Jun 2008 16:22:08 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 Jun 2008 23:21:28 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 554C5234C12E for ; Mon, 2 Jun 2008 16:21:45 -0700 (PDT) Message-ID: <1049603019.1212448905348.JavaMail.jira@brutus> Date: Mon, 2 Jun 2008 16:21:45 -0700 (PDT) From: "Tsz Wo (Nicholas), SZE (JIRA)" To: core-dev@hadoop.apache.org Subject: [jira] Commented: (HADOOP-3177) Expose DFSOutputStream.fsync API though the FileSystem interface In-Reply-To: <593013264.1207342045819.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HADOOP-3177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12601786#action_12601786 ] Tsz Wo (Nicholas), SZE commented on HADOOP-3177: ------------------------------------------------ The class for the wrapperStream is OutputStream. I think it should be java.io.FileOutputStream since we are doing FileSystem. Then, the new method FSDataOutputStream.fsync() just has to call wrapperStream.getFD().sync(). This will work for all FileSystem For DFS, we need to define a new class, say DfsFileDescriptor, extending java.io.FileDescriptor and make DfsFileDescriptor.sync() calls DFSOutputStream.fsync(). For other FileSystem subclass, if getFD() is not defined, we could throw IOException("not supported"). > Expose DFSOutputStream.fsync API though the FileSystem interface > ---------------------------------------------------------------- > > Key: HADOOP-3177 > URL: https://issues.apache.org/jira/browse/HADOOP-3177 > Project: Hadoop Core > Issue Type: Improvement > Components: dfs > Reporter: dhruba borthakur > Assignee: dhruba borthakur > > In the current code, there is a DFSOutputStream.fsync() API that allows a client to flush all buffered data to the datanodes and also persist block locations on the namenode. This API should be exposed through the generic API in the org.hadoop.fs. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.