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

Fixed some code smells in apollo-portal module #2 #3974

Merged
merged 1 commit into from
Sep 11, 2021

Conversation

WillardHu
Copy link
Contributor

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

What's the purpose of this PR

  • Inline variable.
  • Chenge deprecated method.
  • Add final or static final keyword to class field.
  • Set field name to uppercase for static field.
  • Optimize imports.

Which issue(s) this PR fixes:

Fixes #

Brief changelog

Fixed some code smells in apollo-portal module

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.

@codecov-commenter
Copy link

codecov-commenter commented Sep 10, 2021

Codecov Report

Merging #3974 (ab8ba22) into master (bbc2c73) will decrease coverage by 0.04%.
The diff coverage is 23.33%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #3974      +/-   ##
============================================
- Coverage     50.81%   50.76%   -0.05%     
+ Complexity     2470     2468       -2     
============================================
  Files           475      475              
  Lines         14603    14600       -3     
  Branches       1523     1521       -2     
============================================
- Hits           7420     7412       -8     
- Misses         6658     6661       +3     
- Partials        525      527       +2     
Impacted Files Coverage Δ
...mework/apollo/portal/controller/AppController.java 25.88% <0.00%> (-0.31%) ⬇️
...llo/portal/controller/ConfigsImportController.java 33.33% <0.00%> (-4.17%) ⬇️
.../apollo/portal/listener/ConfigPublishListener.java 20.63% <ø> (ø)
...ip/framework/apollo/portal/service/AppService.java 17.80% <0.00%> (+0.47%) ⬆️
...p/framework/apollo/portal/service/ItemService.java 47.56% <0.00%> (-0.32%) ⬇️
...lo/portal/spi/defaultimpl/DefaultEmailService.java 5.40% <ø> (ø)
...al/spi/defaultimpl/DefaultSsoHeartbeatHandler.java 20.00% <0.00%> (ø)
...o/portal/spi/ldap/FilterLdapByGroupUserSearch.java 0.00% <ø> (ø)
...mework/apollo/portal/spi/ldap/LdapUserService.java 0.00% <0.00%> (ø)
...ollo/portal/spi/oidc/OidcLocalUserServiceImpl.java 0.00% <ø> (ø)
... and 8 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 bbc2c73...ab8ba22. Read the comment docs.

Signed-off-by: WillardHu <wei.hu@daocloud.io>
@WillardHu
Copy link
Contributor Author

WillardHu force-pushed the WillardHu:fix/code-smells branch from c646861 to ab8ba22 now

Fixed and rebase master

@WillardHu WillardHu requested a review from nobodyiam September 11, 2021 02:35
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 0b5d227 into apolloconfig:master Sep 11, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Sep 11, 2021
@WillardHu WillardHu deleted the fix/code-smells branch September 13, 2021 08:18
@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