Return-Path: X-Original-To: apmail-flink-dev-archive@www.apache.org Delivered-To: apmail-flink-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9EEBE18C64 for ; Thu, 27 Aug 2015 07:27:51 +0000 (UTC) Received: (qmail 19809 invoked by uid 500); 27 Aug 2015 07:27:46 -0000 Delivered-To: apmail-flink-dev-archive@flink.apache.org Received: (qmail 19747 invoked by uid 500); 27 Aug 2015 07:27:46 -0000 Mailing-List: contact dev-help@flink.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@flink.apache.org Delivered-To: mailing list dev@flink.apache.org Received: (qmail 19730 invoked by uid 99); 27 Aug 2015 07:27:46 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Aug 2015 07:27:46 +0000 Date: Thu, 27 Aug 2015 07:27:46 +0000 (UTC) From: "Arnaud Linz (JIRA)" To: dev@flink.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (FLINK-2580) HadoopDataOutputStream does not expose enough methods of org.apache.hadoop.fs.FSDataOutputStream MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Arnaud Linz created FLINK-2580: ---------------------------------- Summary: HadoopDataOutputStream does not expose enough methods= of org.apache.hadoop.fs.FSDataOutputStream Key: FLINK-2580 URL: https://issues.apache.org/jira/browse/FLINK-2580 Project: Flink Issue Type: Improvement Components: Hadoop Compatibility Reporter: Arnaud Linz Priority: Minor I=E2=80=99ve noticed that when you use org.apache.flink.core.fs.FileSystem = to write into a hdfs file, calling org.apache.flink.runtime.fs.hdfs.HadoopF= ileSystem.create(), it returns a HadoopDataOutputStream that wraps a org.a= pache.hadoop.fs.FSDataOutputStream (under its org.apache.hadoop.hdfs.client= .HdfsDataOutputStream wrappper). =20 However, FSDataOutputStream exposes many methods like flush, getPos etc, = but HadoopDataOutputStream only wraps write & close. =20 For instance, flush() calls the default, empty implementation of OutputStre= am instead of the hadoop one, and that=E2=80=99s confusing. Moreover, becau= se of the restrictive OutputStream interface, hsync() and hflush() are not = exposed to Flink. I see two options: - complete the class to wrap all methods of OutputStream and add a getWrapp= edStream() to access other stuff like hsync(). - get rid of the Hadoop wrapping and directly use Hadoop file system object= s. -- This message was sent by Atlassian JIRA (v6.3.4#6332)