Skip to content

Commit 3923f80

Browse files
committed
Merge branch '4.19'
2 parents f6ceeab + 620ed16 commit 3923f80

File tree

91 files changed

+1859
-1135
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

91 files changed

+1859
-1135
lines changed

api/src/main/java/org/apache/cloudstack/api/command/admin/config/UpdateHypervisorCapabilitiesCmd.java

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ public class UpdateHypervisorCapabilitiesCmd extends BaseCmd {
4343
@Parameter(name = ApiConstants.ID, type = CommandType.UUID, entityType = HypervisorCapabilitiesResponse.class, description = "ID of the hypervisor capability")
4444
private Long id;
4545

46+
@Parameter(name = ApiConstants.HYPERVISOR, type = CommandType.STRING, description = "the hypervisor for which the hypervisor capabilities are to be updated", since = "4.19.1")
47+
private String hypervisor;
48+
49+
@Parameter(name = ApiConstants.HYPERVISOR_VERSION, type = CommandType.STRING, description = "the hypervisor version for which the hypervisor capabilities are to be updated", since = "4.19.1")
50+
private String hypervisorVersion;
51+
4652
@Parameter(name = ApiConstants.SECURITY_GROUP_EANBLED, type = CommandType.BOOLEAN, description = "set true to enable security group for this hypervisor.")
4753
private Boolean securityGroupEnabled;
4854

@@ -73,6 +79,14 @@ public Long getId() {
7379
return id;
7480
}
7581

82+
public String getHypervisor() {
83+
return hypervisor;
84+
}
85+
86+
public String getHypervisorVersion() {
87+
return hypervisorVersion;
88+
}
89+
7690
public Long getMaxGuestsLimit() {
7791
return maxGuestsLimit;
7892
}

api/src/main/java/org/apache/cloudstack/api/command/admin/vm/ImportUnmanagedInstanceCmd.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -201,8 +201,8 @@ public Map<String, Long> getNicNetworkList() {
201201
for (Map<String, String> entry : (Collection<Map<String, String>>)nicNetworkList.values()) {
202202
String nic = entry.get(VmDetailConstants.NIC);
203203
String networkUuid = entry.get(VmDetailConstants.NETWORK);
204-
if (logger.isTraceEnabled()) {
205-
logger.trace(String.format("nic, '%s', goes on net, '%s'", nic, networkUuid));
204+
if (logger.isDebugEnabled()) {
205+
logger.debug(String.format("nic, '%s', goes on net, '%s'", nic, networkUuid));
206206
}
207207
if (StringUtils.isAnyEmpty(nic, networkUuid) || _entityMgr.findByUuid(Network.class, networkUuid) == null) {
208208
throw new InvalidParameterValueException(String.format("Network ID: %s for NIC ID: %s is invalid", networkUuid, nic));
@@ -219,8 +219,8 @@ public Map<String, Network.IpAddresses> getNicIpAddressList() {
219219
for (Map<String, String> entry : (Collection<Map<String, String>>)nicIpAddressList.values()) {
220220
String nic = entry.get(VmDetailConstants.NIC);
221221
String ipAddress = StringUtils.defaultIfEmpty(entry.get(VmDetailConstants.IP4_ADDRESS), null);
222-
if (logger.isTraceEnabled()) {
223-
logger.trace(String.format("nic, '%s', gets ip, '%s'", nic, ipAddress));
222+
if (logger.isDebugEnabled()) {
223+
logger.debug(String.format("nic, '%s', gets ip, '%s'", nic, ipAddress));
224224
}
225225
if (StringUtils.isEmpty(nic)) {
226226
throw new InvalidParameterValueException(String.format("NIC ID: '%s' is invalid for IP address mapping", nic));

api/src/main/java/org/apache/cloudstack/vm/UnmanagedVMsManager.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,15 @@ public interface UnmanagedVMsManager extends VmImportService, UnmanageVMService,
3030
"If set to true, do not remove VM nics (and its MAC addresses) when unmanaging a VM, leaving them allocated but not reserved. " +
3131
"If set to false, nics are removed and MAC addresses can be reassigned", true, ConfigKey.Scope.Zone);
3232

33+
ConfigKey<Integer> RemoteKvmInstanceDisksCopyTimeout = new ConfigKey<>(Integer.class,
34+
"remote.kvm.instance.disks.copy.timeout",
35+
"Advanced",
36+
"30",
37+
"Timeout (in mins) to prepare and copy the disks of remote KVM instance while importing the instance from an external host",
38+
true,
39+
ConfigKey.Scope.Global,
40+
null);
41+
3342
static boolean isSupported(Hypervisor.HypervisorType hypervisorType) {
3443
return hypervisorType == VMware || hypervisorType == KVM;
3544
}

core/src/main/java/com/cloud/agent/api/CheckVolumeAnswer.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
package com.cloud.agent.api;
1919

20-
@LogLevel(LogLevel.Log4jLevel.Trace)
2120
public class CheckVolumeAnswer extends Answer {
2221

2322
private long size;

core/src/main/java/com/cloud/agent/api/CheckVolumeCommand.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121

2222
import com.cloud.agent.api.to.StorageFilerTO;
2323

24-
@LogLevel(LogLevel.Log4jLevel.Trace)
2524
public class CheckVolumeCommand extends Command {
2625

2726
String srcFile;

core/src/main/java/com/cloud/agent/api/CopyRemoteVolumeAnswer.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
package com.cloud.agent.api;
1919

20-
@LogLevel(LogLevel.Log4jLevel.Trace)
2120
public class CopyRemoteVolumeAnswer extends Answer {
2221

2322
private String remoteIp;

core/src/main/java/com/cloud/agent/api/CopyRemoteVolumeCommand.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,13 @@
2121

2222
import com.cloud.agent.api.to.StorageFilerTO;
2323

24-
@LogLevel(LogLevel.Log4jLevel.Trace)
2524
public class CopyRemoteVolumeCommand extends Command {
26-
2725
String remoteIp;
2826
String username;
27+
@LogLevel(LogLevel.Log4jLevel.Off)
2928
String password;
3029
String srcFile;
31-
3230
String tmpPath;
33-
3431
StorageFilerTO storageFilerTO;
3532

3633
public CopyRemoteVolumeCommand(String remoteIp, String username, String password) {

core/src/main/java/com/cloud/agent/api/GetRemoteVmsAnswer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222
import java.util.HashMap;
2323
import java.util.List;
2424

25-
@LogLevel(LogLevel.Log4jLevel.Trace)
2625
public class GetRemoteVmsAnswer extends Answer {
2726

2827
private String remoteIp;
28+
@LogLevel(LogLevel.Log4jLevel.Trace)
2929
private HashMap<String, UnmanagedInstanceTO> unmanagedInstances;
3030

3131
List<String> vmNames;

core/src/main/java/com/cloud/agent/api/GetRemoteVmsCommand.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@
1919

2020
package com.cloud.agent.api;
2121

22-
@LogLevel(LogLevel.Log4jLevel.Trace)
2322
public class GetRemoteVmsCommand extends Command {
2423

2524
String remoteIp;
2625
String username;
26+
@LogLevel(LogLevel.Log4jLevel.Off)
2727
String password;
2828

2929
public GetRemoteVmsCommand(String remoteIp, String username, String password) {

core/src/main/java/com/cloud/agent/api/GetUnmanagedInstancesAnswer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@
2121

2222
import org.apache.cloudstack.vm.UnmanagedInstanceTO;
2323

24-
@LogLevel(LogLevel.Log4jLevel.Trace)
2524
public class GetUnmanagedInstancesAnswer extends Answer {
2625

2726
private String instanceName;
27+
@LogLevel(LogLevel.Log4jLevel.Trace)
2828
private HashMap<String, UnmanagedInstanceTO> unmanagedInstances;
2929

3030
GetUnmanagedInstancesAnswer() {

0 commit comments

Comments
 (0)