[SCB-2663]Support to update microservice properties to the registration center.#3261
Merged
liubao68 merged 1 commit intoapache:masterfrom Aug 9, 2022
Merged
[SCB-2663]Support to update microservice properties to the registration center.#3261liubao68 merged 1 commit intoapache:masterfrom
liubao68 merged 1 commit intoapache:masterfrom
Conversation
hezhangjian
reviewed
Aug 5, 2022
...rc/main/java/org/apache/servicecomb/service/center/client/model/UpdatePropertiesRequest.java
Outdated
Show resolved
Hide resolved
...ient/src/test/java/org/apache/servicecomb/service/center/client/ServiceCenterClientTest.java
Outdated
Show resolved
Hide resolved
d26765a to
c7d7a4f
Compare
Codecov Report
@@ Coverage Diff @@
## master #3261 +/- ##
============================================
- Coverage 77.48% 77.44% -0.05%
- Complexity 1439 1445 +6
============================================
Files 1631 1648 +17
Lines 43455 43635 +180
Branches 3657 3669 +12
============================================
+ Hits 33671 33792 +121
- Misses 8270 8320 +50
- Partials 1514 1523 +9
📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more |
liubao68
reviewed
Aug 7, 2022
...ient/src/test/java/org/apache/servicecomb/service/center/client/ServiceCenterClientTest.java
Outdated
Show resolved
Hide resolved
liubao68
reviewed
Aug 7, 2022
| microservice.setServiceId(serviceId); | ||
|
|
||
| // Need to update microservice properties if we have modified or added properties of microservices. | ||
| Microservice microserviceTemp = new Microservice(); |
Contributor
There was a problem hiding this comment.
When you update microservcie propeties, the client may not be notified for this change. And why you implement this feature and does your scenario need notification?
Contributor
Author
There was a problem hiding this comment.
To support the gray deployment function。
liubao68
reviewed
Aug 8, 2022
| Map<String, String> propertiesTemp = microserviceTemp.getProperties(); | ||
| if (srClient.getMicroservice(serviceId) != null) { | ||
| microserviceTemp.setProperties(srClient.getMicroservice(serviceId).getProperties()); | ||
| microserviceTemp.getProperties().putAll(propertiesTemp); |
Contributor
There was a problem hiding this comment.
srClient.getMicroservice(serviceId) is a remote RPC call, use the result above
liubao68
approved these changes
Aug 9, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow this checklist to help us incorporate your contribution quickly and easily:
[SCB-XXX] Fixes bug in ApproximateQuantiles, where you replaceSCB-XXXwith the appropriate JIRA issue.mvn clean install -Pitto make sure basic checks pass. A more thorough check will be performed on your pull request automatically.