Skip to content
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

[ISSUE-451][Improvement] Read HDFS data files with random sequence to distribute pressure #452

Merged
merged 2 commits into from
Jan 3, 2023

Conversation

zuston
Copy link
Member

@zuston zuston commented Dec 29, 2022

What changes were proposed in this pull request?

[Improvement] Read HDFS data files with random sequence to distribute pressure #452

Why are the changes needed?

In PR #396 to support concurrently writing single partition's data into multiple HDFS files, it's better to randomly read HDFS data files to distribute stress in client side.

Does this PR introduce any user-facing change?

No

How was this patch tested?

Existing UTs

@codecov-commenter
Copy link

codecov-commenter commented Dec 29, 2022

Codecov Report

Merging #452 (5fd7309) into master (3ef80ed) will decrease coverage by 0.04%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##             master     #452      +/-   ##
============================================
- Coverage     58.72%   58.67%   -0.05%     
- Complexity     1652     1654       +2     
============================================
  Files           199      199              
  Lines         11214    11217       +3     
  Branches        996      997       +1     
============================================
- Hits           6585     6582       -3     
- Misses         4237     4243       +6     
  Partials        392      392              
Impacted Files Coverage Δ
...le/storage/handler/impl/HdfsClientReadHandler.java 79.72% <100.00%> (+0.56%) ⬆️
...a/org/apache/uniffle/coordinator/QuotaManager.java 85.29% <0.00%> (-4.26%) ⬇️
...orage/LowestIOSampleCostSelectStorageStrategy.java 70.90% <0.00%> (-3.64%) ⬇️
...e/storage/handler/impl/HdfsShuffleReadHandler.java 56.25% <0.00%> (-1.57%) ⬇️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@@ -143,7 +143,7 @@ protected void init(String fullShufflePath) {
LOG.warn("Can't create ShuffleReaderHandler for " + filePrefix, e);
}
}
readHandlers.sort(Comparator.comparing(HdfsShuffleReadHandler::getFilePrefix));
Collections.shuffle(readHandlers);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we print the file names? It's important for us to know the order.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@zuston zuston requested a review from jerqi January 3, 2023 06:19
Copy link
Contributor

@jerqi jerqi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @zuston

@jerqi jerqi linked an issue Jan 3, 2023 that may be closed by this pull request
3 tasks
@jerqi jerqi changed the title [Improvement] Read HDFS data files with random sequence to distribute pressure [ISSUE-451][Improvement] Read HDFS data files with random sequence to distribute pressure Jan 3, 2023
Copy link
Contributor

@advancedxy advancedxy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@zuston zuston merged commit 9572b84 into apache:master Jan 3, 2023
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.

[Improvement] Read HDFS data files with random sequence to distribute pressure
4 participants