Skip to content

[Python] Allow passing file sizes to FileSystemDataset from Python #37857

Closed

Description

@eeroel

Describe the enhancement requested

When reading Parquet files from table formats such as Delta Lake, file sizes are already known from the table format metadata. However, when building a dataset from fragments using https://arrow.apache.org/docs/python/generated/pyarrow.dataset.FileFormat.html#pyarrow.dataset.FileFormat.make_fragment, there is no way to inform Pyarrow about the file sizes, and this leads to unnecessary HEAD requests in the case of S3. There is already support in Arrow for specifying the file size to avoid these requests to S3, but as far as I can see this is not exposed to PyArrow: #7547

(As a side note, it seems that those HEAD requests in S3Filesystem are always executed on the same thread, which leads to poor concurrency when reading multiple files. Is this a known issue?)

I can try to put together a PR with some kind of an implementation.

Component(s)

Parquet, Python

Activity

  1. changed the title [-]Allow passing file sizes to FileSystemDataset from Python[/-] [+][Python] Allow passing file sizes to FileSystemDataset from Python[/+] on Sep 26, 2023
  2. added a commit that references this issue on Dec 5, 2023
  3. added this to the 15.0.0 milestone on Dec 5, 2023
  4. added a commit that references this issue on Feb 19, 2024
  5. added a commit that references this issue on Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions