From fb66d03bfd5089485362fa489775fbef0da51a5b Mon Sep 17 00:00:00 2001 From: Shireesh Anjal Date: Tue, 2 Aug 2011 18:40:34 +0530 Subject: Modified method executeOnServer NOT to unmarshall the command output if the expected class is String --- .../src/com/gluster/storage/management/gateway/utils/ServerUtil.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/ServerUtil.java b/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/ServerUtil.java index 91c7c81c..6cd8303c 100644 --- a/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/ServerUtil.java +++ b/src/com.gluster.storage.management.gateway/src/com/gluster/storage/management/gateway/utils/ServerUtil.java @@ -149,6 +149,9 @@ public class ServerUtil { Class expectedClass) { try { String output = executeOnServer(serverName, commandWithArgs); + if(expectedClass == String.class) { + return output; + } // In case the script execution exits ungracefully, the agent would return a GenericResponse. // hence pass last argument as true to try GenericResponse unmarshalling in such cases. -- cgit