Skip to content

Support Customizing The Location Of Data Files Written By The Spark Data Source #93

Closed

Description

@mccheah

Currently the Iceberg Data Source Writer requires files to be written to a location relative to the location of the table's metadata files. However, this is an artificial requirement because the manifest specifies URIs of data files that are completely independent of the URI of the table's metadata file system. For example one might want their table metadata to be stored in HDFS but their data files to be stored in S3.

We propose supporting a data source option, iceberg.spark.writer.dataLocation, to allow for overriding the base directory URI of the data files that are to be written.

Activity

  1. rdblue commented on Nov 16, 2018

    @rdblue
    Contributor

    Iceberg doesn't have a requirement for file locations. The Spark writer currently creates paths based on the table location, but it also has a strategy for sharding across S3 prefixes.

    I'm fine adding ways to control data and metadata locations. Is your motivation to use Hadoop tables with S3 locations? If so, then you might want to use iceberg-hive instead.

    Last, if we add a property like this then it should apply for all writers, not just Spark. We are trying to standardize behavior across engines, so the table should be configured, not the table in certain contexts.

  2. mccheah commented on Nov 16, 2018

    @mccheah
    ContributorAuthor

    In #92 (comment) I describe the case where we're using Iceberg as a temporary representation in local disk and then converting the metadata written by Iceberg to metadata in our internal store. This use case is what's driving this as well.

  3. rdblue commented on Dec 8, 2018

    @rdblue
    Contributor

    This has been submitted to the ASF project: apache/iceberg#6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions