Kanagaraj M has uploaded a new change for review.

Change subject: engine: gluster cifs - use enable/disable
......................................................................

engine: gluster cifs - use enable/disable

Exporting gluster volumes through CIFS/SMB is controlled
by the user.cifs volume option. gluster expects the values
for this option should be enable or disable instead on/off.

Change-Id: I505013e47f5905f3c679ac099a6a8163c9d12071
Signed-off-by: Kanagaraj M <[email protected]>
---
M 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterVolumeEntity.java
M 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/constants/gluster/GlusterConstants.java
2 files changed, 6 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/71/18071/1

diff --git 
a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterVolumeEntity.java
 
b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterVolumeEntity.java
index 30d1946..2b7e5eb 100644
--- 
a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterVolumeEntity.java
+++ 
b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterVolumeEntity.java
@@ -326,17 +326,17 @@
 
     public void enableCifs() {
         accessProtocols.add(AccessProtocol.CIFS);
-        setOption(GlusterConstants.OPTION_USER_CIFS, GlusterConstants.ON);
+        setOption(GlusterConstants.OPTION_USER_CIFS, GlusterConstants.ENABLE);
     }
 
     public void disableCifs() {
         accessProtocols.remove(AccessProtocol.CIFS);
-        setOption(GlusterConstants.OPTION_USER_CIFS, GlusterConstants.OFF);
+        setOption(GlusterConstants.OPTION_USER_CIFS, GlusterConstants.DISABLE);
     }
 
     public boolean isCifsEnabled() {
         String cifsEnabled = getOptionValue(GlusterConstants.OPTION_USER_CIFS);
-        return (cifsEnabled == null || 
cifsEnabled.equalsIgnoreCase(GlusterConstants.ON));
+        return (cifsEnabled == null || 
cifsEnabled.equalsIgnoreCase(GlusterConstants.ENABLE));
     }
 
     public List<String> getBrickDirectories() {
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 deecf04..86451c2 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
@@ -5,6 +5,9 @@
     public static final String ON = "on";
     public static final String OFF = "off";
 
+    public static final String ENABLE = "enable";
+    public static final String DISABLE = "disable";
+
     public static final String OPTION_AUTH_ALLOW = "auth.allow";
     public static final String OPTION_NFS_DISABLE = "nfs.disable";
     public static final String OPTION_USER_CIFS = "user.cifs";


-- 
To view, visit http://gerrit.ovirt.org/18071
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I505013e47f5905f3c679ac099a6a8163c9d12071
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Kanagaraj M <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to