Shubhendu Tripathi has uploaded a new change for review. Change subject: gluster: WIP - Disable gluster cli based snapshot scheduling ......................................................................
gluster: WIP - Disable gluster cli based snapshot scheduling Introduced changes to disable gluster CLI based volume snapshot scheduling if engine is used. It looks for the existence of a meta volume in gluster and if so, disables the CLI based volume snapshot scheduling by setting a required flag. Later gluster refers the same flag and does not allow re-enabling of CLI based volume snapshot shcheduling from command line. Change-Id: I6bc06f246f30769c5edaf981876c2a51ddd4fffd Signed-off-by: Shubhendu Tripathi <shtri...@redhat.com> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/ScheduleGlusterVolumeSnapshotCommand.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSGroup.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/constants/gluster/GlusterConstants.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/VDSCommandType.java A backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/gluster/DisableGlusterCliSnapshotSchedulingVDSParameters.java M backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VdsGroupDAODbFacadeImpl.java A backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/gluster/DisableGlusterCliSnapshotSchedulingVDSCommand.java M backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java M backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/IVdsServer.java M backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerConnector.java M backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerWrapper.java M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/volumes/VolumeListModel.java M frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/UIConstants.java A packaging/dbscripts/upgrade/03_06_1250_add_gluster_cli_based_snapshot_scheduled_column_to_vds_groups.sql M packaging/dbscripts/vds_groups_sp.sql 17 files changed, 168 insertions(+), 6 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/45/39945/1 diff --git a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/ScheduleGlusterVolumeSnapshotCommand.java b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/ScheduleGlusterVolumeSnapshotCommand.java index a886c91..d1e9554 100644 --- a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/ScheduleGlusterVolumeSnapshotCommand.java +++ b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/ScheduleGlusterVolumeSnapshotCommand.java @@ -4,8 +4,14 @@ import org.ovirt.engine.core.common.AuditLogType; import org.ovirt.engine.core.common.action.gluster.ScheduleGlusterVolumeSnapshotParameters; +import org.ovirt.engine.core.common.businessentities.VDSGroup; +import org.ovirt.engine.core.common.businessentities.gluster.GlusterVolumeEntity; import org.ovirt.engine.core.common.businessentities.gluster.GlusterVolumeSnapshotSchedule; +import org.ovirt.engine.core.common.constants.gluster.GlusterConstants; import org.ovirt.engine.core.common.errors.VdcBllMessages; +import org.ovirt.engine.core.common.vdscommands.VDSCommandType; +import org.ovirt.engine.core.common.vdscommands.VDSReturnValue; +import org.ovirt.engine.core.common.vdscommands.gluster.DisableGlusterCliSnapshotSchedulingVDSParameters; public class ScheduleGlusterVolumeSnapshotCommand extends ScheduleGlusterVolumeSnapshotCommandBase<ScheduleGlusterVolumeSnapshotParameters> { public ScheduleGlusterVolumeSnapshotCommand(ScheduleGlusterVolumeSnapshotParameters params) { @@ -14,6 +20,11 @@ @Override protected void executeCommand() { + // Check and disable the gluster CLI based snapshot scheduling first + if (!checkAndDisableCLIScheduler()) { + return; + } + // Keep a copy of the execution time before conversion to engine time zone during scheduling Time originalExecutionTime = getSchedule().getExecutionTime(); @@ -31,6 +42,31 @@ } } + private boolean checkAndDisableCLIScheduler() { + GlusterVolumeEntity metaVolume = + getGlusterVolumeDao().getByName(getVdsGroupId(), GlusterConstants.GLUSTER_META_VOLUME_NAME); + if (metaVolume != null) { + VDSGroup cluster = getVdsGroup(); + if (cluster.getGlusterCliBasedScheduling()) { + VDSReturnValue retValue = + runVdsCommand(VDSCommandType.DisableGlusterCliSnapshotScheduling, + new DisableGlusterCliSnapshotSchedulingVDSParameters(getUpServer().getId(), true)); + setSucceeded(retValue.getSucceeded()); + + if (!retValue.getSucceeded()) { + handleVdsError(AuditLogType.GLUSTER_CLI_SNAPSHOT_SCHEDULE_DISABLE_FAILED, retValue.getVdsError() + .getMessage()); + return false; + } else { + cluster.setGlusterCliBasedScheduling(false); + getVdsGroupDAO().update(cluster); + } + } + } + + return true; + } + @Override protected boolean canDoAction() { if (!super.canDoAction()) { diff --git a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java index 67270c7..5e9f7fa 100644 --- a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java +++ b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java @@ -444,6 +444,8 @@ GLUSTER_SETUP_GEOREP_MOUNT_BROKER(4145), GLUSTER_GEOREP_SESSION_CREATE_FAILED(4146, AuditLogSeverity.ERROR), CREATE_GLUSTER_VOLUME_GEOREP_SESSION(4147), + GLUSTER_CLI_SNAPSHOT_SCHEDULE_DISABLE_FAILED(4148, AuditLogSeverity.ERROR), + GLUSTER_CLI_SNAPSHOT_SCHEDULE_DISABLE(4149), USER_FORCE_SELECTED_SPM(159), USER_VDS_RESTART(41), diff --git a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSGroup.java b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSGroup.java index b198c34..333b2148 100644 --- a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSGroup.java +++ b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSGroup.java @@ -69,6 +69,8 @@ private boolean glusterService; + private boolean glusterCliBasedScheduling; + private boolean tunnelMigration; private String emulatedMachine; @@ -246,6 +248,14 @@ public boolean supportsGlusterService() { return glusterService; + } + + public void setGlusterCliBasedScheduling(boolean glusterCliBasedScheduling) { + this.glusterCliBasedScheduling = glusterCliBasedScheduling; + } + + public boolean getGlusterCliBasedScheduling() { + return this.glusterCliBasedScheduling; } public boolean isTunnelMigration() { @@ -442,6 +452,7 @@ result = prime * result + (transparentHugepages ? 1231 : 1237); result = prime * result + (virtService ? 1231 : 1237); result = prime * result + (glusterService ? 1231 : 1237); + result = prime * result + (glusterCliBasedScheduling ? 1231 : 1237); result = prime * result + (tunnelMigration ? 1231 : 1237); result = prime * result + (emulatedMachine == null ? 0 : emulatedMachine.hashCode()); result = prime * result + (trustedService ? 1231 : 1237); @@ -487,6 +498,7 @@ && transparentHugepages == other.transparentHugepages && virtService == other.virtService && glusterService == other.glusterService + && glusterCliBasedScheduling == other.glusterCliBasedScheduling && tunnelMigration == other.tunnelMigration && ObjectUtils.objectsEqual(emulatedMachine, other.emulatedMachine) && trustedService == other.trustedService diff --git a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/constants/gluster/GlusterConstants.java b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/constants/gluster/GlusterConstants.java index 71dba84..49ece9f 100644 --- a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/constants/gluster/GlusterConstants.java +++ b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/constants/gluster/GlusterConstants.java @@ -22,6 +22,8 @@ public static final String FS_TYPE_XFS = "xfs"; + public static final String GLUSTER_META_VOLUME_NAME = "glusterfs_shared_storage"; + // Variables used in audit messages. // Keep the values lowercase to avoid call to String#toLowerCase() public static final String CLUSTER = "cluster"; diff --git a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/VDSCommandType.java b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/VDSCommandType.java index 0c79414..4863c9d 100644 --- a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/VDSCommandType.java +++ b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/VDSCommandType.java @@ -182,6 +182,7 @@ SetGlusterVolumeSnapshotConfig("org.ovirt.engine.core.vdsbroker.gluster"), GetStorageDeviceList("org.ovirt.engine.core.vdsbroker.gluster"), CreateBrick("org.ovirt.engine.core.vdsbroker.gluster"), + DisableGlusterCliSnapshotScheduling("org.ovirt.engine.core.vdsbroker.gluster"), SetNumberOfCpus("org.ovirt.engine.core.vdsbroker"), UpdateVmPolicy("org.ovirt.engine.core.vdsbroker"), diff --git a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/gluster/DisableGlusterCliSnapshotSchedulingVDSParameters.java b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/gluster/DisableGlusterCliSnapshotSchedulingVDSParameters.java new file mode 100644 index 0000000..64d1de6 --- /dev/null +++ b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/vdscommands/gluster/DisableGlusterCliSnapshotSchedulingVDSParameters.java @@ -0,0 +1,29 @@ +package org.ovirt.engine.core.common.vdscommands.gluster; + +import org.ovirt.engine.core.common.vdscommands.VdsIdVDSCommandParametersBase; +import org.ovirt.engine.core.compat.Guid; + +public class DisableGlusterCliSnapshotSchedulingVDSParameters extends VdsIdVDSCommandParametersBase { + protected boolean force; + + public DisableGlusterCliSnapshotSchedulingVDSParameters() { + } + + public DisableGlusterCliSnapshotSchedulingVDSParameters(Guid serverId, boolean force) { + super(serverId); + this.force = force; + } + + public boolean getForce() { + return this.force; + } + + public void setForce(boolean force) { + this.force = force; + } + + @Override + public String toString() { + return String.format("%s, force=%s", super.toString(), getForce()); + } +} diff --git a/backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VdsGroupDAODbFacadeImpl.java b/backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VdsGroupDAODbFacadeImpl.java index 8f7e169..509daaa 100644 --- a/backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VdsGroupDAODbFacadeImpl.java +++ b/backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VdsGroupDAODbFacadeImpl.java @@ -211,6 +211,7 @@ .addValue("migrate_on_error", group.getMigrateOnError()) .addValue("virt_service", group.supportsVirtService()) .addValue("gluster_service", group.supportsGlusterService()) + .addValue("gluster_cli_based_snapshot_scheduled", group.getGlusterCliBasedScheduling()) .addValue("tunnel_migration", group.isTunnelMigration()) .addValue("required_rng_sources", VmRngDevice.sourcesToCsv(group.getRequiredRngSources())) .addValue("emulated_machine", group.getEmulatedMachine()) @@ -277,6 +278,7 @@ entity.setMigrateOnError(MigrateOnErrorOptions.forValue(rs.getInt("migrate_on_error"))); entity.setVirtService(rs.getBoolean("virt_service")); entity.setGlusterService(rs.getBoolean("gluster_service")); + entity.setGlusterCliBasedScheduling(rs.getBoolean("gluster_cli_based_snapshot_scheduled")); entity.setTunnelMigration(rs.getBoolean("tunnel_migration")); entity.getRequiredRngSources().addAll(VmRngDevice.csvToSourcesSet(rs.getString("required_rng_sources"))); entity.setEmulatedMachine(rs.getString("emulated_machine")); diff --git a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/gluster/DisableGlusterCliSnapshotSchedulingVDSCommand.java b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/gluster/DisableGlusterCliSnapshotSchedulingVDSCommand.java new file mode 100644 index 0000000..7c3fe16 --- /dev/null +++ b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/gluster/DisableGlusterCliSnapshotSchedulingVDSCommand.java @@ -0,0 +1,17 @@ +package org.ovirt.engine.core.vdsbroker.gluster; + +import org.ovirt.engine.core.common.vdscommands.gluster.DisableGlusterCliSnapshotSchedulingVDSParameters; + + +public class DisableGlusterCliSnapshotSchedulingVDSCommand<P extends DisableGlusterCliSnapshotSchedulingVDSParameters> extends AbstractGlusterBrokerCommand<P> { + public DisableGlusterCliSnapshotSchedulingVDSCommand(P params) { + super(params); + } + + @Override + protected void executeVdsBrokerCommand() { + boolean force = getParameters().getForce(); + status = getBroker().glusterDisableCliSnapshotScheduling(force); + proceedProxyReturnValue(); + } +} diff --git a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java index ba8c8db..deb31ee 100644 --- a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java +++ b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java @@ -1825,4 +1825,13 @@ Map<String, Object> response = new FutureMap(this.client, request); return new StatusOnlyReturnForXmlRpc(response); } + + @Override + public StatusOnlyReturnForXmlRpc glusterDisableCliSnapshotScheduling(boolean force) { + JsonRpcRequest request = + new RequestBuilder("GlusterSnapshot.disableCliSchedule").withParameter("force", force).build(); + + Map<String, Object> response = new FutureMap(this.client, request).withIgnoreResponseKey(); + return new StatusOnlyReturnForXmlRpc(response); + } } diff --git a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/IVdsServer.java b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/IVdsServer.java index 50686cc..de32081 100644 --- a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/IVdsServer.java +++ b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/IVdsServer.java @@ -397,4 +397,6 @@ StorageDeviceListReturnForXmlRpc glusterStorageDeviceList(); StatusOnlyReturnForXmlRpc hostdevChangeNumvfs(String deviceName, int numOfVfs); + + StatusOnlyReturnForXmlRpc glusterDisableCliSnapshotScheduling(boolean force); } diff --git a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerConnector.java b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerConnector.java index b9ca685..68bd373 100644 --- a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerConnector.java +++ b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerConnector.java @@ -365,4 +365,6 @@ Map<String, Object> raidParams); public Map<String, Object> hostdevChangeNumvfs(String deviceName, int numOfVfs); + + public Map<String, Object> glusterDisableCliSnapshotScheduling(boolean force); } diff --git a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerWrapper.java b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerWrapper.java index c85c5da..cb0cc6c 100644 --- a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerWrapper.java +++ b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/VdsServerWrapper.java @@ -1797,4 +1797,12 @@ } + @Override + public StatusOnlyReturnForXmlRpc glusterDisableCliSnapshotScheduling(boolean force) { + try { + return new StatusOnlyReturnForXmlRpc(vdsServer.glusterDisableCliSnapshotScheduling(force)); + } catch (UndeclaredThrowableException ute) { + throw new XmlRpcRunTimeException(ute); + } + } } diff --git a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java index 53d2c8e..59df550 100644 --- a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java +++ b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java @@ -25,6 +25,7 @@ import org.ovirt.engine.core.common.businessentities.gluster.GlusterVolumeTaskStatusEntity; import org.ovirt.engine.core.common.businessentities.gluster.GlusterVolumeType; import org.ovirt.engine.core.common.businessentities.gluster.Mempool; +import org.ovirt.engine.core.common.constants.gluster.GlusterConstants; import org.ovirt.engine.core.common.job.JobExecutionStatus; import org.ovirt.engine.core.common.queries.VdcQueryReturnValue; import org.ovirt.engine.core.compat.Version; @@ -595,7 +596,12 @@ removeBrickModel.setMigrationSupported(false); removeBrickModel.getMigrateData().setEntity(false); } - else + else if (volumeEntity.getName().equals(GlusterConstants.GLUSTER_META_VOLUME_NAME)) { + removeBrickModel.setMessage(ConstantsManager.getInstance() + .getConstants() + .removeMetaVolumeBricksMessage()); + removeBrickModel.setNote(ConstantsManager.getInstance().getConstants().removeMetaVolumeBricksWarning()); + } else { removeBrickModel.setMessage(ConstantsManager.getInstance().getConstants().removeBricksMessage()); } diff --git a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/volumes/VolumeListModel.java b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/volumes/VolumeListModel.java index d5d6e19..fecbe79 100644 --- a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/volumes/VolumeListModel.java +++ b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/volumes/VolumeListModel.java @@ -26,6 +26,7 @@ import org.ovirt.engine.core.common.businessentities.gluster.GlusterVolumeTaskStatusEntity; import org.ovirt.engine.core.common.businessentities.gluster.GlusterVolumeType; import org.ovirt.engine.core.common.businessentities.gluster.TransportType; +import org.ovirt.engine.core.common.constants.gluster.GlusterConstants; import org.ovirt.engine.core.common.interfaces.SearchType; import org.ovirt.engine.core.common.job.JobExecutionStatus; import org.ovirt.engine.core.common.mode.ApplicationMode; @@ -395,6 +396,15 @@ } + private boolean isMetaVolumeInList(List<GlusterVolumeEntity> volumes) { + for (GlusterVolumeEntity volume : volumes) { + if (volume.getName().equals(GlusterConstants.GLUSTER_META_VOLUME_NAME)) { + return true; + } + } + return false; + } + private void removeVolume() { if (getWindow() != null) { @@ -406,7 +416,11 @@ model.setTitle(ConstantsManager.getInstance().getConstants().removeVolumesTitle()); model.setHelpTag(HelpTag.remove_volume); model.setHashName("remove_volume"); //$NON-NLS-1$ - model.setNote(ConstantsManager.getInstance().getConstants().removeVolumesWarning()); + if (isMetaVolumeInList(Linq.<GlusterVolumeEntity> cast(getSelectedItems()))) { + model.setNote(ConstantsManager.getInstance().getConstants().removeMetaVolumeWarning()); + } else { + model.setNote(ConstantsManager.getInstance().getConstants().removeVolumesWarning()); + } if (getSelectedItems() == null) { return; @@ -1049,7 +1063,11 @@ model.setHelpTag(HelpTag.volume_stop); model.setHashName("volume_stop"); //$NON-NLS-1$ model.setMessage(ConstantsManager.getInstance().getConstants().stopVolumeMessage()); - model.setNote(ConstantsManager.getInstance().getConstants().stopVolumeWarning()); + if (isMetaVolumeInList(Linq.<GlusterVolumeEntity> cast(getSelectedItems()))) { + model.setNote(ConstantsManager.getInstance().getConstants().stopMetaVolumeWarning()); + } else { + model.setNote(ConstantsManager.getInstance().getConstants().stopVolumeWarning()); + } if (getSelectedItems() == null) { return; diff --git a/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/UIConstants.java b/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/UIConstants.java index e4f6631..e70a5e5f 100644 --- a/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/UIConstants.java +++ b/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/UIConstants.java @@ -1748,11 +1748,17 @@ @DefaultStringValue("NOTE:\n -Stopping volume will make its data inaccessible.") String stopVolumeWarning(); + @DefaultStringValue("NOTE:\n -Stopping meta volume will impact normal working of features like volume snapshot, geo-replication etc.") + String stopMetaVolumeWarning(); + @DefaultStringValue("Remove Volume") String removeVolumesTitle(); @DefaultStringValue("NOTE:\n -Removing volume will erase all information about the volume.") String removeVolumesWarning(); + + @DefaultStringValue("NOTE:\n - Removing meta volume will impact normal working of features like volume snapshot, geo-replication etc.") + String removeMetaVolumeWarning(); @DefaultStringValue("Remove Bricks") String removeBricksTitle(); @@ -1775,6 +1781,12 @@ @DefaultStringValue("Are you sure you want to remove the following Brick(s)?") String removeBricksMessage(); + @DefaultStringValue("Are you sure you want to remove the following Brick(s) from meta volume?") + String removeMetaVolumeBricksMessage(); + + @DefaultStringValue("NOTE:\n -Removing bricks from meta volume will impact normal working of features like volume snapshot, geo-replication etc.") + String removeMetaVolumeBricksWarning(); + @DefaultStringValue("NOTE:\n -Removing brick(s) can result in data loss.") String removeBricksWarning(); diff --git a/packaging/dbscripts/upgrade/03_06_1250_add_gluster_cli_based_snapshot_scheduled_column_to_vds_groups.sql b/packaging/dbscripts/upgrade/03_06_1250_add_gluster_cli_based_snapshot_scheduled_column_to_vds_groups.sql new file mode 100644 index 0000000..b99bc79 --- /dev/null +++ b/packaging/dbscripts/upgrade/03_06_1250_add_gluster_cli_based_snapshot_scheduled_column_to_vds_groups.sql @@ -0,0 +1,2 @@ +select fn_db_add_column('vds_groups', 'gluster_cli_based_snapshot_scheduled', 'BOOLEAN NOT NULL DEFAULT TRUE'); + diff --git a/packaging/dbscripts/vds_groups_sp.sql b/packaging/dbscripts/vds_groups_sp.sql index 397f15f..f0f0b36 100644 --- a/packaging/dbscripts/vds_groups_sp.sql +++ b/packaging/dbscripts/vds_groups_sp.sql @@ -21,6 +21,7 @@ v_migrate_on_error INTEGER, v_virt_service BOOLEAN, v_gluster_service BOOLEAN, + v_gluster_cli_based_snapshot_scheduled BOOLEAN, v_tunnel_migration BOOLEAN, v_emulated_machine VARCHAR(40), v_detect_emulated_machine BOOLEAN, @@ -49,11 +50,11 @@ AS $procedure$ BEGIN INSERT INTO vds_groups(vds_group_id,description, name, free_text_comment, cpu_name, storage_pool_id, max_vds_memory_over_commit, count_threads_as_cores, compatibility_version, - transparent_hugepages, migrate_on_error, virt_service, gluster_service, tunnel_migration, emulated_machine, detect_emulated_machine, trusted_service, ha_reservation, optional_reason, maintenance_reason_required, cluster_policy_id, + transparent_hugepages, migrate_on_error, virt_service, gluster_service, gluster_cli_based_snapshot_scheduled, tunnel_migration, emulated_machine, detect_emulated_machine, trusted_service, ha_reservation, optional_reason, maintenance_reason_required, cluster_policy_id, cluster_policy_custom_properties, enable_balloon, architecture, optimization_type, spice_proxy, enable_ksm, serial_number_policy, custom_serial_number, required_rng_sources, skip_fencing_if_sd_active, skip_fencing_if_connectivity_broken, hosts_with_broken_connectivity_threshold, fencing_enabled, is_auto_converge, is_migrate_compressed) VALUES(v_vds_group_id,v_description, v_name, v_free_text_comment, v_cpu_name, v_storage_pool_id, v_max_vds_memory_over_commit, v_count_threads_as_cores, v_compatibility_version, - v_transparent_hugepages, v_migrate_on_error, v_virt_service, v_gluster_service, v_tunnel_migration, v_emulated_machine, v_detect_emulated_machine, v_trusted_service, v_ha_reservation, v_optional_reason, v_maintenance_reason_required, v_cluster_policy_id, v_cluster_policy_custom_properties, v_enable_balloon, + v_transparent_hugepages, v_migrate_on_error, v_virt_service, v_gluster_service, v_gluster_cli_based_snapshot_scheduled, v_tunnel_migration, v_emulated_machine, v_detect_emulated_machine, v_trusted_service, v_ha_reservation, v_optional_reason, v_maintenance_reason_required, v_cluster_policy_id, v_cluster_policy_custom_properties, v_enable_balloon, v_architecture, v_optimization_type, v_spice_proxy, v_enable_ksm, v_serial_number_policy, v_custom_serial_number, v_required_rng_sources, v_skip_fencing_if_sd_active, v_skip_fencing_if_connectivity_broken, v_hosts_with_broken_connectivity_threshold, v_fencing_enabled, v_is_auto_converge, v_is_migrate_compressed); END; $procedure$ @@ -76,6 +77,7 @@ v_migrate_on_error INTEGER, v_virt_service BOOLEAN, v_gluster_service BOOLEAN, + v_gluster_cli_based_snapshot_scheduled BOOLEAN, v_tunnel_migration BOOLEAN, v_emulated_machine VARCHAR(40), v_detect_emulated_machine BOOLEAN, @@ -112,7 +114,7 @@ count_threads_as_cores = v_count_threads_as_cores, compatibility_version = v_compatibility_version,transparent_hugepages = v_transparent_hugepages, migrate_on_error = v_migrate_on_error, - virt_service = v_virt_service, gluster_service = v_gluster_service, tunnel_migration = v_tunnel_migration, + virt_service = v_virt_service, gluster_service = v_gluster_service, gluster_cli_based_snapshot_scheduled = v_gluster_cli_based_snapshot_scheduled, tunnel_migration = v_tunnel_migration, emulated_machine = v_emulated_machine, detect_emulated_machine = v_detect_emulated_machine, trusted_service = v_trusted_service, ha_reservation = v_ha_reservation , optional_reason = v_optional_reason, maintenance_reason_required = v_maintenance_reason_required, cluster_policy_id = v_cluster_policy_id, cluster_policy_custom_properties = v_cluster_policy_custom_properties, enable_balloon = v_enable_balloon, architecture = v_architecture, optimization_type = v_optimization_type, spice_proxy = v_spice_proxy, enable_ksm = v_enable_ksm, -- To view, visit https://gerrit.ovirt.org/39945 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I6bc06f246f30769c5edaf981876c2a51ddd4fffd Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Shubhendu Tripathi <shtri...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches