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

[#1711] feat(server): Introduce the reconfigurable conf #1712

Merged
merged 8 commits into from
May 22, 2024

Conversation

zuston
Copy link
Member

@zuston zuston commented May 13, 2024

What changes were proposed in this pull request?

Introduce the reconfigurable conf for server or other componts.

Why are the changes needed?

Fix: #1711

Does this PR introduce any user-facing change?

No.

How was this patch tested?

Unit tests.

@zuston zuston marked this pull request as draft May 13, 2024 09:49
@zuston
Copy link
Member Author

zuston commented May 13, 2024

I drafted this impl, please take a look. @jerqi

Copy link

github-actions bot commented May 13, 2024

Test Results

 2 419 files  +28   2 419 suites  +28   4h 58m 9s ⏱️ + 1m 23s
   933 tests + 5     932 ✅ + 5   1 💤 ±0  0 ❌ ±0 
10 819 runs  +65  10 805 ✅ +65  14 💤 ±0  0 ❌ ±0 

Results for commit 0bdfdeb. ± Comparison against base commit d4a5fb7.

♻️ This comment has been updated with latest results.

@zuston
Copy link
Member Author

zuston commented May 15, 2024

I drafted this impl, please take a look. @jerqi

gentle ping @jerqi

@zuston
Copy link
Member Author

zuston commented May 17, 2024

I drafted this impl, please take a look. @jerqi

gentle ping @jerqi

ping again

@zuston zuston marked this pull request as ready for review May 22, 2024 06:15
@zuston zuston changed the title [#1711] feat(server): introduce the reconfigurable conf [#1711] feat(server): Introduce the reconfigurable conf May 22, 2024
@zuston zuston requested a review from jerqi May 22, 2024 06:52
@@ -569,7 +573,7 @@ public <T> RssConf set(ConfigOption<T> option, T value) {
return this;
}

<T> void setValueInternal(String key, T value) {
public <T> void setValueInternal(String key, T value) {
Copy link
Contributor

Choose a reason for hiding this comment

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

This method should be used in the class inner from the name. Could we avoid using it?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't use this, let me recover.

}
}

private boolean isSame(Object v1, Object v2) {
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 use Objects.equal?

Copy link
Member Author

@zuston zuston May 22, 2024

Choose a reason for hiding this comment

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

Let me take a try

@@ -57,6 +57,10 @@ public Set<String> getKeySet() {
return Sets.newHashSet();
}

public Object getObject(String key, Object defaultValue) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we need this?

Copy link
Member Author

Choose a reason for hiding this comment

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

Used by reconfigurableManager to check whether the prev value is same with the latest value, and then output the log if they are different.

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't see that this method is called this method in any place.

Copy link
Member Author

Choose a reason for hiding this comment

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

My fault. I forgot to remove this after refactor.

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.

@codecov-commenter
Copy link

codecov-commenter commented May 22, 2024

Codecov Report

Attention: Patch coverage is 66.25000% with 27 lines in your changes are missing coverage. Please review.

Project coverage is 54.13%. Comparing base (6f6d35a) to head (ce5230a).
Report is 27 commits behind head on master.

Files Patch % Lines
...ache/uniffle/common/ReconfigurableConfManager.java 65.78% 24 Missing and 2 partials ⚠️
.../java/org/apache/uniffle/server/ShuffleServer.java 0.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1712      +/-   ##
============================================
- Coverage     54.86%   54.13%   -0.74%     
- Complexity     2358     2928     +570     
============================================
  Files           368      432      +64     
  Lines         16379    23398    +7019     
  Branches       1504     2186     +682     
============================================
+ Hits           8986    12666    +3680     
- Misses         6862     9958    +3096     
- Partials        531      774     +243     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@zuston zuston merged commit 5dd4eef into apache:master May 22, 2024
39 checks passed
@zuston
Copy link
Member Author

zuston commented May 22, 2024

Merged. Thanks @jerqi review

zuston added a commit to zuston/incubator-uniffle that referenced this pull request May 27, 2024
…#1712)

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

Introduce the reconfigurable conf for server or other componts.

### Why are the changes needed?

Fix: apache#1711

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

No.

### How was this patch tested?

Unit tests.
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.

[FEATURE] Refactor reconfigurable conf framework and apply to shuffleServer module
3 participants