GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Merge branch '4.22' · NetApp/cloudstack@4ce5291

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • PendingReleaseNotes
  • api/src
    • main/java
      • com/cloud/host
        • Host.java
      • org/apache/cloudstack/api
        • command/user/vmsnapshot
          • CreateVMSnapshotCmd.java
        • response
          • ImageStoreDetailResponse.java
          • NetworkOfferingResponse.java
          • ProjectResponse.java
    • test/java/org/apache/cloudstack/api/response
      • ImageStoreDetailResponseTest.java
      • ProjectResponseTest.java
  • core/src/main/java/com/cloud/agent/api/storage
    • CreateDiskOnlyVmSnapshotAnswer.java
    • CreateDiskOnlyVmSnapshotCommand.java
    • DeleteDiskOnlyVmSnapshotCommand.java
    • RevertDiskOnlyVmSnapshotCommand.java
  • engine
    • orchestration/src
      • main/java/com/cloud
        • agent/manager
          • AgentAttache.java
          • AgentManagerImpl.java
        • vm
          • VirtualMachineManagerImpl.java
      • test/java/com/cloud
        • agent/manager
          • AgentAttacheSendNextTest.java
          • AgentManagerImplTest.java
        • vm
          • VirtualMachineManagerImplTest.java
    • storage
      • snapshot/src
        • main/java/org/apache/cloudstack/storage/vmsnapshot
          • KvmFileBasedStorageVmSnapshotStrategy.java
        • test/java/org/apache/cloudstack/storage/vmsnapshot
          • KvmFileBasedStorageVmSnapshotStrategyTest.java
      • volume/src/main/java/org/apache/cloudstack/storage/volume
        • VolumeServiceImpl.java
  • framework
    • config/src
      • main/java/org/apache/cloudstack/framework/config/impl
        • ConfigDepotImpl.java
      • test/java/org/apache/cloudstack/framework/config/impl
        • ConfigDepotImplTest.java
    • jobs/src/main/java/org/apache/cloudstack/framework/jobs/impl
      • AsyncJobManagerImpl.java
  • plugins
    • hypervisors/kvm/src
      • main/java
        • com/cloud/hypervisor/kvm
          • resource
            • LibvirtComputingResource.java
            • wrapper
              • LibvirtCreateDiskOnlyVMSnapshotCommandWrapper.java
              • LibvirtDeleteDiskOnlyVMSnapshotCommandWrapper.java
              • LibvirtReadyCommandWrapper.java
              • LibvirtRestoreBackupCommandWrapper.java
              • LibvirtRevertDiskOnlyVMSnapshotCommandWrapper.java
          • storage
            • KVMStorageProcessor.java
        • org/apache/cloudstack/utils/linux
          • KVMHostInfo.java
      • test/java/com/cloud/hypervisor/kvm
        • resource/wrapper
          • LibvirtDiskOnlyVMSnapshotCommandWrapperTest.java
          • LibvirtRestoreBackupCommandWrapperTest.java
        • storage
          • KVMStorageProcessorTest.java
    • storage/sharedfs/storagevm/src
      • main/java/org/apache/cloudstack/storage/sharedfs/lifecycle
        • StorageVmSharedFSLifeCycle.java
      • test/java/org/apache/cloudstack/storage/sharedfs/lifecycle
        • StorageVmSharedFSLifeCycleTest.java
    • user-authenticators/saml2/src
      • main/java/org/apache/cloudstack/api/command
        • SAML2LogoutAPIAuthenticatorCmd.java
      • test/java/org/apache/cloudstack/api/command
        • SAML2LogoutAPIAuthenticatorCmdTest.java
  • server/src
    • main/java/com/cloud
      • api
        • ApiResponseHelper.java
        • ApiServlet.java
      • consoleproxy
        • ConsoleProxyManager.java
        • ConsoleProxyManagerImpl.java
      • network
        • lb
          • LoadBalancingRulesManagerImpl.java
        • vpn
          • RemoteAccessVpnManagerImpl.java
      • server
        • StatsCollector.java
      • vm
        • UserVmManagerImpl.java
    • test/java/com/cloud
      • network
        • lb
          • LoadBalancingRulesManagerImplTest.java
        • vpn
          • RemoteAccessVpnManagerImplTest.java
      • server
        • StatsCollectorTest.java
      • vm
        • UserVmManagerImplTest.java
  • services/console-proxy/server/src/main/java/com/cloud/consoleproxy
    • ConsoleProxy.java
    • ConsoleProxyGCThread.java
    • ConsoleProxyNoVNCHandler.java
    • ConsoleProxyNoVncClient.java
    • vnc
      • NoVncClient.java
      • network
        • NioSocket.java
        • NioSocketHandler.java
        • NioSocketHandlerImpl.java
  • tools/checkstyle/src/main/resources
    • cloud-pmd.xml
  • ui
    • public/locales
      • en.json
    • src
      • components
        • offering
          • ComputeOfferingForm.vue
        • view
          • InstanceVolumesStoragePoolSelectListView.vue
          • ListView.vue
          • StoragePoolSelectView.vue
          • VolumeStoragePoolSelectForm.vue
      • config/section
        • compute.js
        • network.js
        • offering.js
      • utils
        • util.js
      • views
        • compute
          • AutoScaleDownPolicyTab.vue
          • AutoScaleLoadBalancing.vue
          • AutoScaleUpPolicyTab.vue
          • AutoScaleVmProfile.vue
          • DeployVM.vue
          • MigrateWizard.vue
        • dashboard
          • SetupTwoFaAtLogin.vue
          • VerifyTwoFa.vue
        • iam
          • SetupTwoFaAtUserProfile.vue
    • tests/unit/views/compute
      • DeployVMTemplateHypervisor.spec.js

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎PendingReleaseNotes‎

Copy file name to clipboardExpand all lines: PendingReleaseNotes
+14Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,17 @@ example.ver.1 > example.ver.2:
3939
which can now be attached to Instances. This is to prevent the Secondary
4040
Storage to grow to enormous sizes as Linux Distributions keep growing in
4141
size while a stripped down Linux should fit on a 2.88MB floppy.
42+
43+
4.22.0.0 > 4.22.0.1:
44+
* Disk-only instance snapshots for KVM UEFI VMs now include a sidecar copy of
45+
the active NVRAM state so revert operations restore both disk and firmware
46+
boot state consistently.
47+
48+
* UEFI disk-only instance snapshots taken before this change do not contain an
49+
NVRAM sidecar and cannot be safely reverted. Take a new snapshot after
50+
upgrading before relying on revert for UEFI VMs.
51+
52+
* Taking a disk-only instance snapshot for KVM UEFI VMs now briefly suspends
53+
the guest while the NVRAM sidecar is copied, so that the captured firmware
54+
state is consistent with the disk snapshot. Non-UEFI VMs are unaffected and
55+
continue to snapshot live.
Collapse file

‎api/src/main/java/com/cloud/host/Host.java‎

Copy file name to clipboardExpand all lines: api/src/main/java/com/cloud/host/Host.java
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ public static String[] toStrings(Host.Type... types) {
5555
}
5656

5757
String HOST_UEFI_ENABLE = "host.uefi.enable";
58+
String HOST_KVM_DISK_ONLY_VM_SNAPSHOT_NVRAM = "host.kvm.diskonlyvmsnapshot.nvram";
5859
String HOST_VOLUME_ENCRYPTION = "host.volume.encryption";
5960
String HOST_INSTANCE_CONVERSION = "host.instance.conversion";
6061
String HOST_VDDK_SUPPORT = "host.vddk.support";
Collapse file

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

Copy file name to clipboardExpand all lines: api/src/main/java/org/apache/cloudstack/api/command/user/vmsnapshot/CreateVMSnapshotCmd.java
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@
3636
import com.cloud.uservm.UserVm;
3737
import com.cloud.vm.snapshot.VMSnapshot;
3838

39-
@APICommand(name = "createVMSnapshot", description = "Creates Snapshot for an Instance.", responseObject = VMSnapshotResponse.class, since = "4.2.0", entityType = {VMSnapshot.class},
39+
@APICommand(name = "createVMSnapshot", description = "Creates Snapshot for an Instance. Running KVM UEFI disk-only snapshots briefly suspend the Instance while copying NVRAM state.",
40+
responseObject = VMSnapshotResponse.class, since = "4.2.0", entityType = {VMSnapshot.class},
4041
requestHasSensitiveInfo = false, responseHasSensitiveInfo = false)
4142
public class CreateVMSnapshotCmd extends BaseAsyncCreateCmd {
4243

Collapse file

‎api/src/main/java/org/apache/cloudstack/api/response/ImageStoreDetailResponse.java‎

Copy file name to clipboardExpand all lines: api/src/main/java/org/apache/cloudstack/api/response/ImageStoreDetailResponse.java
+3-1Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
// under the License.
1717
package org.apache.cloudstack.api.response;
1818

19+
import java.util.Objects;
20+
1921
import com.google.gson.annotations.SerializedName;
2022

2123
import org.apache.cloudstack.api.BaseResponse;
@@ -81,7 +83,7 @@ public boolean equals(Object obj) {
8183
return false;
8284
} else if (!oid.equals(other.getName()))
8385
return false;
84-
else if (this.getValue().equals(other.getValue()))
86+
else if (!Objects.equals(this.getValue(), other.getValue()))
8587
return false;
8688
return true;
8789
}
Collapse file

‎api/src/main/java/org/apache/cloudstack/api/response/NetworkOfferingResponse.java‎

Copy file name to clipboardExpand all lines: api/src/main/java/org/apache/cloudstack/api/response/NetworkOfferingResponse.java
+12Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,10 @@ public class NetworkOfferingResponse extends BaseResponseWithAnnotations {
9191
@Param(description = "The ID of the service offering used by virtual router provider")
9292
private String serviceOfferingId;
9393

94+
@SerializedName(ApiConstants.SERVICE_OFFERING_NAME)
95+
@Param(description = "the name of the service offering used by virtual router provider")
96+
private String serviceOfferingName;
97+
9498
@SerializedName(ApiConstants.SERVICE)
9599
@Param(description = "The list of supported services", responseObject = ServiceResponse.class)
96100
private List<ServiceResponse> services;
@@ -330,4 +334,12 @@ public String getRoutingMode() {
330334
public void setRoutingMode(String routingMode) {
331335
this.routingMode = routingMode;
332336
}
337+
338+
public String getServiceOfferingName() {
339+
return serviceOfferingName;
340+
}
341+
342+
public void setServiceOfferingName(String serviceOfferingName) {
343+
this.serviceOfferingName = serviceOfferingName;
344+
}
333345
}
Collapse file

‎api/src/main/java/org/apache/cloudstack/api/response/ProjectResponse.java‎

Copy file name to clipboardExpand all lines: api/src/main/java/org/apache/cloudstack/api/response/ProjectResponse.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,7 @@ public void setNetworkAvailable(String networkAvailable) {
452452

453453
@Override
454454
public void setVpcLimit(String vpcLimit) {
455-
this.vpcLimit = networkLimit;
455+
this.vpcLimit = vpcLimit;
456456
}
457457

458458
@Override
Collapse file

‎api/src/test/java/org/apache/cloudstack/api/response/ImageStoreDetailResponseTest.java‎

Copy file name to clipboard
+45Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
// Licensed to the Apache Software Foundation (ASF) under one
2+
// or more contributor license agreements. See the NOTICE file
3+
// distributed with this work for additional information
4+
// regarding copyright ownership. The ASF licenses this file
5+
// to you under the Apache License, Version 2.0 (the
6+
// "License"); you may not use this file except in compliance
7+
// with the License. You may obtain a copy of the License at
8+
//
9+
// http://www.apache.org/licenses/LICENSE-2.0
10+
//
11+
// Unless required by applicable law or agreed to in writing,
12+
// software distributed under the License is distributed on an
13+
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
// KIND, either express or implied. See the License for the
15+
// specific language governing permissions and limitations
16+
// under the License.
17+
package org.apache.cloudstack.api.response;
18+
19+
import org.junit.Assert;
20+
import org.junit.Test;
21+
22+
public class ImageStoreDetailResponseTest {
23+
24+
@Test
25+
public void equalsIsTrueForSameNameAndValue() {
26+
ImageStoreDetailResponse a = new ImageStoreDetailResponse("key", "value");
27+
ImageStoreDetailResponse b = new ImageStoreDetailResponse("key", "value");
28+
Assert.assertEquals(a, b);
29+
Assert.assertEquals(a.hashCode(), b.hashCode());
30+
}
31+
32+
@Test
33+
public void equalsIsFalseWhenValueDiffers() {
34+
ImageStoreDetailResponse a = new ImageStoreDetailResponse("key", "value");
35+
ImageStoreDetailResponse c = new ImageStoreDetailResponse("key", "other");
36+
Assert.assertNotEquals(a, c);
37+
}
38+
39+
@Test
40+
public void equalsIsFalseWhenNameDiffers() {
41+
ImageStoreDetailResponse a = new ImageStoreDetailResponse("key", "value");
42+
ImageStoreDetailResponse d = new ImageStoreDetailResponse("other", "value");
43+
Assert.assertNotEquals(a, d);
44+
}
45+
}
Collapse file

‎api/src/test/java/org/apache/cloudstack/api/response/ProjectResponseTest.java‎

Copy file name to clipboard
+34Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
// Licensed to the Apache Software Foundation (ASF) under one
2+
// or more contributor license agreements. See the NOTICE file
3+
// distributed with this work for additional information
4+
// regarding copyright ownership. The ASF licenses this file
5+
// to you under the Apache License, Version 2.0 (the
6+
// "License"); you may not use this file except in compliance
7+
// with the License. You may obtain a copy of the License at
8+
//
9+
// http://www.apache.org/licenses/LICENSE-2.0
10+
//
11+
// Unless required by applicable law or agreed to in writing,
12+
// software distributed under the License is distributed on an
13+
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
// KIND, either express or implied. See the License for the
15+
// specific language governing permissions and limitations
16+
// under the License.
17+
package org.apache.cloudstack.api.response;
18+
19+
import org.junit.Assert;
20+
import org.junit.Test;
21+
import org.springframework.test.util.ReflectionTestUtils;
22+
23+
public class ProjectResponseTest {
24+
25+
@Test
26+
public void setVpcLimitStoresItsOwnParameterNotTheNetworkLimit() {
27+
ProjectResponse response = new ProjectResponse();
28+
response.setNetworkLimit("5");
29+
response.setVpcLimit("10");
30+
31+
Assert.assertEquals("10", ReflectionTestUtils.getField(response, "vpcLimit"));
32+
Assert.assertEquals("5", ReflectionTestUtils.getField(response, "networkLimit"));
33+
}
34+
}
Collapse file

‎core/src/main/java/com/cloud/agent/api/storage/CreateDiskOnlyVmSnapshotAnswer.java‎

Copy file name to clipboardExpand all lines: core/src/main/java/com/cloud/agent/api/storage/CreateDiskOnlyVmSnapshotAnswer.java
+11Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,24 @@
2626
public class CreateDiskOnlyVmSnapshotAnswer extends Answer {
2727

2828
protected Map<String, Long> mapVolumeToSnapshotSize;
29+
private String nvramSnapshotPath;
2930

3031
public CreateDiskOnlyVmSnapshotAnswer(Command command, boolean success, String details, Map<String, Long> mapVolumeToSnapshotSize) {
32+
this(command, success, details, mapVolumeToSnapshotSize, null);
33+
}
34+
35+
public CreateDiskOnlyVmSnapshotAnswer(Command command, boolean success, String details, Map<String, Long> mapVolumeToSnapshotSize,
36+
String nvramSnapshotPath) {
3137
super(command, success, details);
3238
this.mapVolumeToSnapshotSize = mapVolumeToSnapshotSize;
39+
this.nvramSnapshotPath = nvramSnapshotPath;
3340
}
3441

3542
public Map<String, Long> getMapVolumeToSnapshotSize() {
3643
return mapVolumeToSnapshotSize;
3744
}
45+
46+
public String getNvramSnapshotPath() {
47+
return nvramSnapshotPath;
48+
}
3849
}
Collapse file

‎core/src/main/java/com/cloud/agent/api/storage/CreateDiskOnlyVmSnapshotCommand.java‎

Copy file name to clipboardExpand all lines: core/src/main/java/com/cloud/agent/api/storage/CreateDiskOnlyVmSnapshotCommand.java
+17Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,22 @@
3030
public class CreateDiskOnlyVmSnapshotCommand extends VMSnapshotBaseCommand {
3131

3232
protected VirtualMachine.State vmState;
33+
private final String vmUuid;
34+
private final boolean uefiEnabled;
3335

3436
List<Pair<VolumeObjectTO, String>> volumeTosAndNewPaths;
3537

3638
public CreateDiskOnlyVmSnapshotCommand(String vmName, VMSnapshotTO snapshot, List<Pair<VolumeObjectTO, String>> volumeTosAndNewPaths, String guestOSType, VirtualMachine.State vmState) {
39+
this(vmName, null, snapshot, volumeTosAndNewPaths, guestOSType, vmState, false);
40+
}
41+
42+
public CreateDiskOnlyVmSnapshotCommand(String vmName, String vmUuid, VMSnapshotTO snapshot, List<Pair<VolumeObjectTO, String>> volumeTosAndNewPaths, String guestOSType,
43+
VirtualMachine.State vmState, boolean uefiEnabled) {
3744
super(vmName, snapshot, null, guestOSType);
45+
this.vmUuid = vmUuid;
3846
this.vmState = vmState;
3947
this.volumeTosAndNewPaths = volumeTosAndNewPaths;
48+
this.uefiEnabled = uefiEnabled;
4049
}
4150

4251
public VirtualMachine.State getVmState() {
@@ -46,4 +55,12 @@ public VirtualMachine.State getVmState() {
4655
public List<Pair<VolumeObjectTO, String>> getVolumeTosAndNewPaths() {
4756
return volumeTosAndNewPaths;
4857
}
58+
59+
public String getVmUuid() {
60+
return vmUuid;
61+
}
62+
63+
public boolean isUefiEnabled() {
64+
return uefiEnabled;
65+
}
4966
}

0 commit comments

Comments
0 (0)
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.