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

[#408] test: fix memory check failure in ShuffleBufferManagerTest#bufferSizeTest #657

Merged
merged 2 commits into from
Feb 27, 2023

Conversation

zuston
Copy link
Member

@zuston zuston commented Feb 25, 2023

What changes were proposed in this pull request?

Fix memory check failure due to the execution sequence in ShuffleBufferManagerTest#bufferSizeTest

Why are the changes needed?

Flaky test fix: #408

Does this PR introduce any user-facing change?

No.

How was this patch tested?

Existing UTs

@codecov-commenter
Copy link

codecov-commenter commented Feb 25, 2023

Codecov Report

Merging #657 (60650c0) into master (18c738e) will increase coverage by 2.24%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##             master     #657      +/-   ##
============================================
+ Coverage     60.60%   62.84%   +2.24%     
- Complexity     1799     1800       +1     
============================================
  Files           216      202      -14     
  Lines         12458    10494    -1964     
  Branches       1052     1052              
============================================
- Hits           7550     6595     -955     
+ Misses         4500     3551     -949     
+ Partials        408      348      -60     
Impacted Files Coverage Δ
deploy/kubernetes/operator/pkg/utils/config.go
...rnetes/operator/pkg/webhook/inspector/inspector.go
...oy/kubernetes/operator/pkg/controller/util/util.go
deploy/kubernetes/operator/pkg/webhook/manager.go
...y/kubernetes/operator/pkg/webhook/inspector/pod.go
deploy/kubernetes/operator/pkg/utils/util.go
deploy/kubernetes/operator/pkg/utils/rss.go
...oy/kubernetes/operator/pkg/utils/shufflerserver.go
...pkg/controller/sync/shuffleserver/shuffleserver.go
...tor/pkg/controller/sync/coordinator/coordinator.go
... and 4 more

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

// Need to wait for `event.doCleanup` to be executed
// to ensure the correctness of subsequent checks of
// `shuffleBufferManager.getUsedMemory()` and `shuffleBufferManager.getInFlushSize()`.
Thread.sleep(100);
Copy link
Contributor

@advancedxy advancedxy Feb 25, 2023

Choose a reason for hiding this comment

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

is there some way to ensure event.doCleanup is executed?

This still could be flaky. But I'm ok to merge if there's no easy way.

@zuston zuston requested a review from jerqi February 27, 2023 07:15
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

@zuston zuston merged commit ace21e6 into apache:master Feb 27, 2023
@zuston zuston deleted the issue-408 branch February 27, 2023 08:17
@jerqi
Copy link
Contributor

jerqi commented Feb 27, 2023

@zuston Could you cherry-pick and commit to branch 0.7?

zuston added a commit that referenced this pull request Mar 7, 2023
…ferSizeTest (#657)

### What changes were proposed in this pull request?

Fix memory check failure due to the execution sequence in ShuffleBufferManagerTest#bufferSizeTest

### Why are the changes needed?

Flaky test fix: #408

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

Existing UTs
advancedxy pushed a commit to advancedxy/incubator-uniffle that referenced this pull request Mar 21, 2023
…st#bufferSizeTest (apache#657)

### What changes were proposed in this pull request?

Fix memory check failure due to the execution sequence in ShuffleBufferManagerTest#bufferSizeTest

### Why are the changes needed?

Flaky test fix: apache#408

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

Existing UTs
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.

Flaky Test: ShuffleBufferManagerTest#bufferSizeTest
4 participants