Skip to content

Commit 8b4f719

Browse files
review
1 parent 71bad8f commit 8b4f719

File tree

6 files changed

+20
-5
lines changed

6 files changed

+20
-5
lines changed

api/src/main/java/org/apache/cloudstack/api/command/user/snapshot/CopySnapshotCmd.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,11 @@ public class CopySnapshotCmd extends BaseAsyncCmd implements UserCmd {
9797
"The snapshot will always be made available in the zone in which the volume is present. Currently supported for StorPool only")
9898
protected List<Long> storagePoolIds;
9999

100-
@Parameter (name = ApiConstants.USE_STORAGE_REPLICATION, type=CommandType.BOOLEAN, since = "4.21.0", description = "Enables the snapshot to be copied to the supported primary storages when the config 'use.storage.replication' set to true for the storage or globally. Supports only StorPool storage for now.")
100+
@Parameter (name = ApiConstants.USE_STORAGE_REPLICATION,
101+
type=CommandType.BOOLEAN,
102+
since = "4.21.0",
103+
description = "Enables the snapshot to be copied to the supported primary storages when the config 'use.storage.replication' set to true for the storage or globally. " +
104+
"This is supported only for StorPool storage for now.")
101105
protected Boolean useStorageReplication;
102106

103107
/////////////////////////////////////////////////////

api/src/main/java/org/apache/cloudstack/api/command/user/snapshot/CreateSnapshotCmd.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,10 @@ public class CreateSnapshotCmd extends BaseAsyncCreateCmd {
112112
since = "4.21.0")
113113
protected List<Long> storagePoolIds;
114114

115-
@Parameter (name = ApiConstants.USE_STORAGE_REPLICATION, type=CommandType.BOOLEAN, description = "Enables the snapshot to be copied to the supported primary storages when the config 'use.storage.replication' set to true for the storage or globally. Supports only StorPool storage for now.")
115+
@Parameter (name = ApiConstants.USE_STORAGE_REPLICATION,
116+
type=CommandType.BOOLEAN,
117+
description = "Enables the snapshot to be copied to the supported primary storages when the config 'use.storage.replication' set to true for the storage or globally. " +
118+
"This is supported only for StorPool storage for now.")
116119
protected Boolean useStorageReplication;
117120

118121
private String syncObjectType = BaseAsyncCmd.snapshotHostSyncObject;

api/src/main/java/org/apache/cloudstack/api/command/user/snapshot/CreateSnapshotPolicyCmd.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,11 @@ public class CreateSnapshotPolicyCmd extends BaseCmd {
9494
since = "4.21.0")
9595
protected List<Long> storagePoolIds;
9696

97-
@Parameter (name = ApiConstants.USE_STORAGE_REPLICATION, type=CommandType.BOOLEAN, since = "4.21.0", description = "Enables the snapshot to be copied to the supported primary storages when the config 'use.storage.replication' set to true for the storage or globally. Supports only StorPool storage for now.")
97+
@Parameter (name = ApiConstants.USE_STORAGE_REPLICATION,
98+
type=CommandType.BOOLEAN,
99+
since = "4.21.0",
100+
description = "Enables the snapshot to be copied to the supported primary storages when the config 'use.storage.replication' set to true for the storage or globally. " +
101+
"This is supported only for StorPool storage for now.")
98102
protected Boolean useStorageReplication;
99103
/////////////////////////////////////////////////////
100104
/////////////////// Accessors ///////////////////////

server/src/main/java/com/cloud/storage/snapshot/SnapshotManager.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,9 @@ public interface SnapshotManager extends Configurable {
6868
"Whether to show chain size (sum of physical size of snapshot and all its parents) for incremental snapshots in the snapshot response",
6969
true, ConfigKey.Scope.Global, null);
7070

71-
ConfigKey<Boolean> UseStorageReplication = new ConfigKey<>(Boolean.class, "use.storage.replication", "Snapshots", "false", "For snapshot copy to another primary storage in a different zone. Supports only StorPool storage for now", true, ConfigKey.Scope.StoragePool, null);
71+
ConfigKey<Boolean> UseStorageReplication = new ConfigKey<>(Boolean.class, "use.storage.replication", "Snapshots", "false",
72+
"For snapshot copy to another primary storage in a different zone. This is supported only for StorPool storage for now.",
73+
true, ConfigKey.Scope.StoragePool, null);
7274

7375
void deletePoliciesForVolume(Long volumeId);
7476

ui/src/views/storage/FormSchedule.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@
173173
<a-form-item name="useStorageReplication" ref="useStorageReplication">
174174
<template #label>
175175
<tooltip-label :title="$t('label.usestoragereplication')" :tooltip="apiParams.usestoragereplication.description" />
176-
</template>
176+
</template>
177177
<a-switch v-model:checked="form.useStorageReplication" />
178178
</a-form-item>
179179
<a-form-item v-if="isAdmin && form.useStorageReplication" ref="storageids" name="storageids">

ui/src/views/storage/SnapshotZones.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,7 @@ import { isAdmin } from '@/role'
239239
import OsLogo from '@/components/widgets/OsLogo'
240240
import ResourceIcon from '@/components/view/ResourceIcon'
241241
import TooltipButton from '@/components/widgets/TooltipButton'
242+
import TooltipLabel from '@/components/widgets/TooltipLabel'
242243
import BulkActionProgress from '@/components/view/BulkActionProgress'
243244
import Status from '@/components/widgets/Status'
244245
import eventBus from '@/config/eventBus'
@@ -247,6 +248,7 @@ export default {
247248
name: 'SnapshotZones',
248249
components: {
249250
TooltipButton,
251+
TooltipLabel,
250252
OsLogo,
251253
ResourceIcon,
252254
BulkActionProgress,

0 commit comments

Comments
 (0)