Skip to content

Commit eb74c40

Browse files
author
GutoVeronezi
committed
Merge remote-tracking branch 'apache-github/main' into HEAD
2 parents ffab07f + 8b721a9 commit eb74c40

File tree

237 files changed

+5867
-3357
lines changed

Some content is hidden

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

237 files changed

+5867
-3357
lines changed

agent/conf/agent.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,5 +289,5 @@ iscsi.session.cleanup.enabled=false
289289
# Manually set the host CPU MHz, in cases where CPU scaling support detected value is wrong
290290
# host.cpu.manual.speed.mhz=0
291291

292-
# Enable/disable IO driver for Qemu / It's enabled by default on KVM agents
292+
# Enable/disable IO driver for Qemu (in case it is not set CloudStack can also detect if its supported by qemu)
293293
# enable.io.uring=true

agent/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
<parent>
2525
<groupId>org.apache.cloudstack</groupId>
2626
<artifactId>cloudstack</artifactId>
27-
<version>4.17.0.0-SNAPSHOT</version>
27+
<version>4.18.0.0-SNAPSHOT</version>
2828
</parent>
2929
<dependencies>
3030
<dependency>

agent/src/main/java/com/cloud/agent/AgentShell.java

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
import com.cloud.utils.backoff.BackoffAlgorithm;
2828
import com.cloud.utils.backoff.impl.ConstantTimeBackoff;
2929
import com.cloud.utils.exception.CloudRuntimeException;
30-
import org.apache.cloudstack.utils.security.KeyStoreUtils;
3130
import org.apache.commons.daemon.Daemon;
3231
import org.apache.commons.daemon.DaemonContext;
3332
import org.apache.commons.daemon.DaemonInitException;
@@ -375,7 +374,6 @@ public void init(String[] args) throws ConfigurationException {
375374

376375
loadProperties();
377376
parseCommand(args);
378-
enableSSL();
379377

380378
if (s_logger.isDebugEnabled()) {
381379
List<String> properties = Collections.list((Enumeration<String>)_properties.propertyNames());
@@ -399,27 +397,6 @@ public void init(String[] args) throws ConfigurationException {
399397
_backoff.configure("ConstantTimeBackoff", new HashMap<String, Object>());
400398
}
401399

402-
private void enableSSL() {
403-
final File agentFile = PropertiesUtil.findConfigFile("agent.properties");
404-
if (agentFile == null) {
405-
s_logger.info("Failed to find agent.properties file");
406-
return;
407-
}
408-
String keystorePass = getProperty(null, "keystore.passphrase");
409-
if (StringUtils.isBlank(keystorePass)) {
410-
s_logger.info("Failed to find passphrase for keystore: " + KeyStoreUtils.KS_FILENAME);
411-
return;
412-
}
413-
final String keyStoreFile = agentFile.getParent() + "/" + KeyStoreUtils.KS_FILENAME;
414-
File f = new File(keyStoreFile);
415-
if (f.exists() && !f.isDirectory()) {
416-
System.setProperty("javax.net.ssl.trustStore", keyStoreFile);
417-
System.setProperty("javax.net.ssl.trustStorePassword", keystorePass);
418-
} else {
419-
s_logger.info("Failed to find keystore file: " + keyStoreFile);
420-
}
421-
}
422-
423400
private void launchAgent() throws ConfigurationException {
424401
String resourceClassNames = getProperty(null, "resource");
425402
s_logger.trace("resource=" + resourceClassNames);

agent/src/main/java/com/cloud/agent/properties/AgentProperties.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,6 @@ public class AgentProperties{
5454
*/
5555
public static final Property<Boolean> ENABLE_MANUALLY_SETTING_CPU_TOPOLOGY_ON_KVM_VM = new Property<Boolean>("enable.manually.setting.cpu.topology.on.kvm.vm", true);
5656

57-
/**
58-
* Enable manually IO driver on KVM's VM. <br>
59-
* Data type: boolean.<br>
60-
* Default value: true.
61-
*/
62-
public static final Property<Boolean> ENABLE_IO_URING = new Property<Boolean>("enable.io.uring", true);
63-
6457
public static class Property <T>{
6558
private final String name;
6659
private final T defaultValue;

api/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
<parent>
2525
<groupId>org.apache.cloudstack</groupId>
2626
<artifactId>cloudstack</artifactId>
27-
<version>4.17.0.0-SNAPSHOT</version>
27+
<version>4.18.0.0-SNAPSHOT</version>
2828
</parent>
2929
<dependencies>
3030
<dependency>

api/src/main/java/com/cloud/network/Ipv6Service.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,6 @@ public interface Ipv6Service extends PluggableService, Configurable {
7070

7171
void updateNicIpv6(NicProfile nic, DataCenter dc, Network network) throws InsufficientAddressCapacityException;
7272

73-
void releasePublicIpv6ForNic(Network network, String nicIpv6Address);
74-
7573
List<String> getPublicIpv6AddressesForNetwork(Network network);
7674

7775
void updateIpv6RoutesForVpcResponse(Vpc vpc, VpcResponse response);

api/src/main/java/com/cloud/server/ManagementService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,7 @@ public interface ManagementService {
405405
*/
406406
Pair<List<? extends StoragePool>, List<? extends StoragePool>> listStoragePoolsForMigrationOfVolume(Long volumeId);
407407

408-
Pair<List<? extends StoragePool>, List<? extends StoragePool>> listStoragePoolsForMigrationOfVolumeInternal(Long volumeId, Long newDiskOfferingId, Long newSize, Long newMinIops, Long newMaxIops, boolean keepSourceStoragePool);
408+
Pair<List<? extends StoragePool>, List<? extends StoragePool>> listStoragePoolsForMigrationOfVolumeInternal(Long volumeId, Long newDiskOfferingId, Long newSize, Long newMinIops, Long newMaxIops, boolean keepSourceStoragePool, boolean bypassStorageTypeCheck);
409409

410410
String[] listEventTypes();
411411

api/src/main/java/org/apache/cloudstack/api/ApiConstants.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -905,6 +905,9 @@ public class ApiConstants {
905905

906906
public static final String ADMINS_ONLY = "adminsonly";
907907
public static final String ANNOTATION_FILTER = "annotationfilter";
908+
public static final String LOGIN = "login";
909+
public static final String LOGOUT = "logout";
910+
public static final String LIST_IDPS = "listIdps";
908911

909912
public enum BootType {
910913
UEFI, BIOS;

api/src/main/java/org/apache/cloudstack/api/command/user/network/CreateNetworkCmd.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -346,8 +346,7 @@ public long getEntityOwnerId() {
346346

347347
@Override
348348
// an exception thrown by createNetwork() will be caught by the dispatcher.
349-
public
350-
void execute() throws InsufficientCapacityException, ConcurrentOperationException, ResourceAllocationException {
349+
public void execute() throws InsufficientCapacityException, ConcurrentOperationException, ResourceAllocationException {
351350
Network result = _networkService.createGuestNetwork(this);
352351
if (result != null) {
353352
NetworkResponse response = _responseGenerator.createNetworkResponse(getResponseView(), result);

api/src/main/java/org/apache/cloudstack/api/command/user/vmsnapshot/CreateVMSnapshotCmd.java

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

1818
package org.apache.cloudstack.api.command.user.vmsnapshot;
1919

20+
import com.cloud.utils.exception.CloudRuntimeException;
2021
import org.apache.cloudstack.acl.SecurityChecker.AccessType;
2122
import org.apache.cloudstack.api.ACL;
2223
import org.apache.cloudstack.api.APICommand;
@@ -90,9 +91,16 @@ public Long getVmId() {
9091

9192
@Override
9293
public void create() throws ResourceAllocationException {
93-
VMSnapshot vmsnapshot = _vmSnapshotService.allocVMSnapshot(getVmId(), getDisplayName(), getDescription(), snapshotMemory());
94+
VMSnapshot vmsnapshot;
95+
try {
96+
vmsnapshot = _vmSnapshotService.allocVMSnapshot(getVmId(), getDisplayName(), getDescription(), snapshotMemory());
97+
} catch (CloudRuntimeException e) {
98+
throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to create vm snapshot: " + e.getMessage(), e);
99+
}
100+
94101
if (vmsnapshot != null) {
95102
setEntityId(vmsnapshot.getId());
103+
setEntityUuid(vmsnapshot.getUuid());
96104
} else {
97105
throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to create vm snapshot");
98106
}

0 commit comments

Comments
 (0)