Skip to content

[SPARK-14259] [SQL] Merging small files together based on the cost of opening #12095

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

davies
Copy link
Contributor

@davies davies commented Mar 31, 2016

What changes were proposed in this pull request?

This PR basically re-do the things in #12068 but with a different model, which should work better in case of small files with different sizes.

How was this patch tested?

Updated existing tests.

Ran a query on thousands of partitioned small files locally, with all default settings (the cost to open a file should be over estimated), the durations of tasks become smaller and smaller, which is good (the last few tasks will be shortest).

@davies
Copy link
Contributor Author

davies commented Mar 31, 2016

ping @nongli

@SparkQA
Copy link

SparkQA commented Mar 31, 2016

Test build #54661 has finished for PR 12095 at commit 504a762.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@davies
Copy link
Contributor Author

davies commented Apr 4, 2016

cc @marmbrus

@marmbrus
Copy link
Contributor

marmbrus commented Apr 4, 2016

Lgtm, though I still think pipelined reading is the right thing to do long term.

@davies
Copy link
Contributor Author

davies commented Apr 4, 2016

Pipelined reading is a good idea to overlap opening and processing, will be done in another PR. After that, this PR is still useful, thinking of lots of tiny files (100ms to open, but 1ms to process), opening these files will be majority of the time, we should not add thousands of tiny files into one partition.

@davies
Copy link
Contributor Author

davies commented Apr 4, 2016

Merging this into master, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants