Skip to content

Commit 33b494a

Browse files
committed
Merge branch 'main' into nsx-integration
2 parents 8a87eaa + cb62ce6 commit 33b494a

184 files changed

Lines changed: 6029 additions & 1221 deletions

File tree

Some content is hidden

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

.github/workflows/build.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ concurrency:
2323
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
2424
cancel-in-progress: true
2525

26+
permissions:
27+
contents: read
28+
2629
jobs:
2730
build:
2831
runs-on: ubuntu-22.04

.github/workflows/ci.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ concurrency:
2323
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
2424
cancel-in-progress: true
2525

26+
permissions:
27+
contents: read
28+
2629
jobs:
2730
build:
2831
if: github.repository == 'apache/cloudstack'
@@ -108,7 +111,8 @@ jobs:
108111
smoke/test_reset_configuration_settings
109112
smoke/test_reset_vm_on_reboot
110113
smoke/test_resource_accounting
111-
smoke/test_resource_detail",
114+
smoke/test_resource_detail
115+
smoke/test_global_acls",
112116
"smoke/test_router_dhcphosts
113117
smoke/test_router_dns
114118
smoke/test_router_dnsservice

.github/workflows/rat.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ concurrency:
2323
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
2424
cancel-in-progress: true
2525

26+
permissions:
27+
contents: read
28+
2629
jobs:
2730
build:
2831
runs-on: ubuntu-22.04

.github/workflows/ui.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ concurrency:
2323
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
2424
cancel-in-progress: true
2525

26+
permissions:
27+
contents: read
28+
2629
jobs:
2730
build:
2831
runs-on: ubuntu-22.04

PULL_REQUEST_TEMPLATE.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ This PR...
1010
<!-- For addressing multiple issues/PRs, use multiple "Fixes: #<id>" -->
1111
<!-- Fixes: # -->
1212

13-
<!--- ********************************************************************************* -->
14-
<!--- NOTE: AUTOMATATION USES THE DESCRIPTIONS TO SET LABELS AND PRODUCE DOCUMENTATION. -->
13+
<!--- ******************************************************************************* -->
14+
<!--- NOTE: AUTOMATION USES THE DESCRIPTIONS TO SET LABELS AND PRODUCE DOCUMENTATION. -->
1515
<!--- PLEASE PUT AN 'X' in only **ONE** box -->
16-
<!--- ********************************************************************************* -->
16+
<!--- ******************************************************************************* -->
1717

1818
### Types of changes
1919

agent/conf/agent.properties

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -407,3 +407,15 @@ iscsi.session.cleanup.enabled=false
407407
# The path of an executable file/script for host health check for CloudStack to Auto Disable/Enable the host
408408
# depending on the return value of the file/script
409409
# agent.health.check.script.path=
410+
411+
# Time interval (in milliseconds) between KVM heartbeats.
412+
# kvm.heartbeat.update.frequency=60000
413+
414+
# Number of maximum tries to KVM heartbeats.
415+
# kvm.heartbeat.update.max.tries=5
416+
417+
# Time amount (in milliseconds) for the KVM heartbeat retry sleep.
418+
# kvm.heartbeat.update.retry.sleep=10000
419+
420+
# Timeout (in milliseconds) of the KVM heartbeat checker.
421+
# kvm.heartbeat.checker.timeout=360000

agent/src/main/java/com/cloud/agent/dao/impl/PropertiesStorage.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,11 +92,14 @@ public synchronized boolean configure(String name, Map<String, Object> params) {
9292
file = new File(path);
9393
try {
9494
if (!file.createNewFile()) {
95-
s_logger.error("Unable to create _file: " + file.getAbsolutePath());
95+
s_logger.error(String.format("Unable to create _file: %s", file.getAbsolutePath()));
9696
return false;
9797
}
9898
} catch (IOException e) {
99-
s_logger.error("Unable to create _file: " + file.getAbsolutePath(), e);
99+
s_logger.error(String.format("Unable to create file: %s", file.getAbsolutePath()));
100+
if (s_logger.isDebugEnabled()) {
101+
s_logger.debug(String.format("IOException while trying to create file: %s", file.getAbsolutePath()), e);
102+
}
100103
return false;
101104
}
102105
}

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

Lines changed: 35 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -539,10 +539,10 @@ public class AgentProperties{
539539
/**
540540
* Heartbeat update timeout (in ms).<br>
541541
* Depending on the use case, this timeout might need increasing/decreasing.<br>
542-
* Data type: Integer.<br>
543-
* Default value: <code>60000</code>
542+
* Data type: Long.<br>
543+
* Default value: <code>60000L</code>
544544
*/
545-
public static final Property<Integer> HEARTBEAT_UPDATE_TIMEOUT = new Property<>("heartbeat.update.timeout", 60000);
545+
public static final Property<Long> HEARTBEAT_UPDATE_TIMEOUT = new Property<>("heartbeat.update.timeout", 60000L);
546546

547547
/**
548548
* The timeout (in seconds) to retrieve the target's domain ID when migrating a VM with KVM. <br>
@@ -740,6 +740,38 @@ public Property<Integer> getWorkers() {
740740
*/
741741
public static final Property<String> CONTROL_CIDR = new Property<>("control.cidr", "169.254.0.0/16");
742742

743+
/**
744+
* Time interval (in milliseconds) between KVM heartbeats. <br>
745+
* This property is for KVM only.
746+
* Data type: Long.<br>
747+
* Default value: <code>60000l</code>
748+
*/
749+
public static final Property<Long> KVM_HEARTBEAT_UPDATE_FREQUENCY = new Property<>("kvm.heartbeat.update.frequency", 60000L);
750+
751+
/**
752+
* Number of maximum tries to KVM heartbeats. <br>
753+
* This property is for KVM only.
754+
* Data type: Long.<br>
755+
* Default value: <code>5l</code>
756+
*/
757+
public static final Property<Long> KVM_HEARTBEAT_UPDATE_MAX_TRIES = new Property<>("kvm.heartbeat.update.max.tries", 5L);
758+
759+
/**
760+
* Time amount (in milliseconds) for the KVM heartbeat retry sleep. <br>
761+
* This property is for KVM only.
762+
* Data type: Long.<br>
763+
* Default value: <code>10000l</code>
764+
*/
765+
public static final Property<Long> KVM_HEARTBEAT_UPDATE_RETRY_SLEEP = new Property<>("kvm.heartbeat.update.retry.sleep", 10000L);
766+
767+
/**
768+
* Timeout (in milliseconds) of the KVM heartbeat checker. <br>
769+
* This property is for KVM only.
770+
* Data type: Long.<br>
771+
* Default value: <code>360000l</code>
772+
*/
773+
public static final Property<Long> KVM_HEARTBEAT_CHECKER_TIMEOUT = new Property<>("kvm.heartbeat.checker.timeout", 360000L);
774+
743775
public static class Property <T>{
744776
private String name;
745777
private T defaultValue;

api/src/main/java/com/cloud/agent/api/StoragePoolInfo.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,13 @@ public StoragePoolInfo(String uuid, String host, String hostPath, String localPa
5252
this.details = details;
5353
}
5454

55+
public StoragePoolInfo(String uuid, String host, String hostPath, String localPath, StoragePoolType poolType, long capacityBytes, long availableBytes,
56+
Map<String, String> details, String name) {
57+
this(uuid, host, hostPath, localPath, poolType, capacityBytes, availableBytes);
58+
this.details = details;
59+
this.name = name;
60+
}
61+
5562
public long getCapacityBytes() {
5663
return capacityBytes;
5764
}

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

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@
2525
import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd;
2626
import org.apache.cloudstack.api.command.admin.network.ListGuestVlansCmd;
2727
import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd;
28+
import org.apache.cloudstack.api.command.user.address.RemoveQuarantinedIpCmd;
29+
import org.apache.cloudstack.api.command.user.address.UpdateQuarantinedIpCmd;
2830
import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd;
2931
import org.apache.cloudstack.api.command.user.network.CreateNetworkPermissionsCmd;
3032
import org.apache.cloudstack.api.command.user.network.ListNetworkPermissionsCmd;
@@ -115,6 +117,8 @@ IpAddress allocatePortableIP(Account ipOwner, int regionId, Long zoneId, Long ne
115117

116118
IpAddress getIp(long id);
117119

120+
IpAddress getIp(String ipAddress);
121+
118122
Network updateGuestNetwork(final UpdateNetworkCmd cmd);
119123

120124
/**
@@ -249,4 +253,8 @@ Network createPrivateNetwork(String networkName, String displayText, long physic
249253
boolean resetNetworkPermissions(ResetNetworkPermissionsCmd resetNetworkPermissionsCmd);
250254

251255
void validateIfServiceOfferingIsActiveAndSystemVmTypeIsDomainRouter(final Long serviceOfferingId) throws InvalidParameterValueException;
256+
257+
PublicIpQuarantine updatePublicIpAddressInQuarantine(UpdateQuarantinedIpCmd cmd);
258+
259+
void removePublicIpAddressFromQuarantine(RemoveQuarantinedIpCmd cmd);
252260
}

0 commit comments

Comments
 (0)