-
Notifications
You must be signed in to change notification settings - Fork 1.2k
cleanup LDAP code according to warnings #11436
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
base: main
Are you sure you want to change the base?
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests.
Additional details and impacted files@@ Coverage Diff @@
## main #11436 +/- ##
=============================================
- Coverage 17.36% 3.63% -13.73%
=============================================
Files 5886 441 -5445
Lines 525645 37023 -488622
Branches 64156 6785 -57371
=============================================
- Hits 91257 1345 -89912
+ Misses 424093 35517 -388576
+ Partials 10295 161 -10134
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
@blueorangutan package |
@DaanHoogland a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 14608 |
@blueorangutan test |
@DaanHoogland a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests |
[SF] Trillian test result (tid-14056)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR performs cleanup of the LDAP code according to compiler warnings. It removes unused methods, simplifies string concatenations, eliminates dead code, and modernizes various patterns without changing functionality.
- Removes deprecated/unused methods and constructors
- Simplifies string building patterns and improves logging
- Updates method visibility and parameters for better consistency
Reviewed Changes
Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
ADLdapUserManagerImplTest.java | Updates test setup to use static mocking and fixes assertion methods |
LinkAccountToLdapCmdTest.java | Adds missing test assertion for account name |
LdapListUsersCmdTest.java | Fixes method name from isACloudstackUser to isACloudStackUser |
LdapConfigurationDaoImpl.java | Removes unused find method overload |
LdapConfigurationDao.java | Removes unused method signature and improves javadoc |
OpenLdapUserManagerImpl.java | Major refactoring: simplifies string building, uses static methods, improves logging |
LdapUserManager.java | Removes public modifiers from interface methods |
LdapUser.java | Makes memberships field final |
LdapTrustMapVO.java | Removes empty constructor and updates hashCode implementation |
LdapManagerImpl.java | Simplifies logging and removes unused method |
LdapManager.java | Removes unused method signature |
LdapContextFactory.java | Uses static methods for configuration access |
LdapConfiguration.java | Makes many methods static and removes deprecated constructor |
LdapAuthenticator.java | Improves logging and simplifies conditional logic |
ADLdapUserManagerImpl.java | Uses static configuration methods and improves string building |
LinkAccountToLdapResponse.java | Adds missing getter method |
Various command classes | Removes empty constructors, improves parameter documentation, and modernizes patterns |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
...er-authenticators/ldap/src/main/java/org/apache/cloudstack/ldap/OpenLdapUserManagerImpl.java
Show resolved
Hide resolved
8deca7b
to
3b806be
Compare
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 14659 |
Packaging result [SF]: ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 14664 |
Description
This PR was part of investigation into the current LDAP workings, to find out that the issue under investigation was a user issue. I think this can be merged, but it has no functional changes.
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?
How did you try to break this feature and the system with this change?