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

Make the constructor of AbstractApolloHttpException implementation class to support string template #3999

Merged
merged 1 commit into from
Sep 27, 2021

Conversation

WillardHu
Copy link
Contributor

Signed-off-by: WillardHu wei.hu@daocloud.io

What's the purpose of this PR

Make the constructor of AbstractApolloHttpException implementation class to support string template. The method com.google.common.base.Strings.lenientFormat(..) performs better than String.format(..).

Which issue(s) this PR fixes:

Fixes #

Brief changelog

Make the constructor of AbstractApolloHttpException implementation class to support string template

Follow this checklist to help us incorporate your contribution quickly and easily:

  • Read the Contributing Guide before making this pull request.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Write necessary unit tests to verify the code.
  • Run mvn clean test to make sure this pull request doesn't break anything.
  • Update the CHANGES log.

…ass to support string template

Signed-off-by: WillardHu <wei.hu@daocloud.io>
@WillardHu WillardHu force-pushed the fix/biz-except-constructor branch from a30bf2b to 538f7f8 Compare September 24, 2021 01:44
@codecov-commenter
Copy link

Codecov Report

Merging #3999 (538f7f8) into master (2fb3479) will increase coverage by 0.05%.
The diff coverage is 11.11%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #3999      +/-   ##
============================================
+ Coverage     51.21%   51.27%   +0.05%     
- Complexity     2500     2505       +5     
============================================
  Files           482      482              
  Lines         14776    14773       -3     
  Branches       1527     1527              
============================================
+ Hits           7568     7575       +7     
+ Misses         6677     6667      -10     
  Partials        531      531              
Impacted Files Coverage Δ
...inservice/controller/InstanceConfigController.java 92.77% <0.00%> (ø)
...apollo/adminservice/controller/ItemController.java 8.53% <0.00%> (+0.10%) ⬆️
...nservice/controller/NamespaceBranchController.java 11.36% <0.00%> (ø)
...o/adminservice/controller/NamespaceController.java 15.62% <0.00%> (+0.91%) ⬆️
...llo/adminservice/controller/ReleaseController.java 23.72% <0.00%> (ø)
.../common/exception/AbstractApolloHttpException.java 42.85% <0.00%> (+42.85%) ⬆️
...k/apollo/common/exception/BadRequestException.java 0.00% <0.00%> (ø)
...work/apollo/common/exception/ServiceException.java 0.00% <0.00%> (ø)
...inservice/controller/ReleaseHistoryController.java 25.00% <100.00%> (ø)
...ork/apollo/common/exception/NotFoundException.java 100.00% <100.00%> (+100.00%) ⬆️
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2fb3479...538f7f8. Read the comment docs.

@WillardHu WillardHu requested a review from nobodyiam September 26, 2021 07:40
Copy link
Member

@nobodyiam nobodyiam left a comment

Choose a reason for hiding this comment

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

LGTM

@nobodyiam nobodyiam merged commit c488995 into apolloconfig:master Sep 27, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Sep 27, 2021
@WillardHu WillardHu deleted the fix/biz-except-constructor branch September 27, 2021 01:44
@nobodyiam nobodyiam added this to the 1.10.0 milestone Oct 6, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants