You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2021/08/24 13:04:13 UTC
[GitHub] [cloudstack] GabrielBrascher commented on a change in pull request #5337: Bypass empty string check for username and password
GabrielBrascher commented on a change in pull request #5337:
URL: https://github.com/apache/cloudstack/pull/5337#discussion_r694829490
##########
File path: server/src/main/java/com/cloud/resource/ResourceManagerImpl.java
##########
@@ -687,6 +688,10 @@ public Discoverer getMatchingDiscover(final Hypervisor.HypervisorType hypervisor
if ((clusterName != null || clusterId != null) && podId == null) {
throw new InvalidParameterValueException("Can't specify cluster without specifying the pod");
}
+ if (!HypervisorType.VMware.toString().equalsIgnoreCase(hypervisorType) &&
+ (Strings.isNullOrEmpty(username) || Strings.isNullOrEmpty(password))) {
Review comment:
I agree with @GutoVeronezi.
Nowadays we already have some discussions about adopting `org.apache.commons.lang3.StringUtils` vs `com.cloud.utils.StringUtils` "_facade_" (@DaanHoogland :slightly_smiling_face:); with the `google.common.base.Strings` adds a third variable to this "equation".
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org