You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by da...@apache.org on 2015/05/21 17:49:44 UTC

[04/10] git commit: updated refs/heads/master to 84266b1

api: iso: fix and reformat descriptions

Signed-off-by: Daan Hoogland <da...@gmail.com>


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/a1f58c48
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/a1f58c48
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/a1f58c48

Branch: refs/heads/master
Commit: a1f58c48ec0b2dd33232c7a0e04af1f99289421e
Parents: 897c738
Author: Rene Moser <re...@apache.org>
Authored: Thu May 21 09:56:13 2015 +0200
Committer: Daan Hoogland <da...@gmail.com>
Committed: Thu May 21 17:49:18 2015 +0200

----------------------------------------------------------------------
 .../cloudstack/api/command/user/iso/AttachIsoCmd.java   | 10 +++++-----
 .../cloudstack/api/command/user/iso/CopyIsoCmd.java     |  2 +-
 .../cloudstack/api/command/user/iso/DeleteIsoCmd.java   |  4 ++--
 .../cloudstack/api/command/user/iso/DetachIsoCmd.java   |  6 +++---
 .../cloudstack/api/command/user/iso/ExtractIsoCmd.java  |  6 +++---
 .../api/command/user/iso/ListIsoPermissionsCmd.java     |  2 +-
 .../cloudstack/api/command/user/iso/ListIsosCmd.java    |  4 ++--
 .../cloudstack/api/command/user/iso/RegisterIsoCmd.java | 12 ++++++------
 .../cloudstack/api/command/user/iso/UpdateIsoCmd.java   |  2 +-
 .../api/command/user/iso/UpdateIsoPermissionsCmd.java   |  2 +-
 10 files changed, 25 insertions(+), 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/AttachIsoCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/AttachIsoCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/AttachIsoCmd.java
index 1b8087b..c1d67e5 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/AttachIsoCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/AttachIsoCmd.java
@@ -78,7 +78,7 @@ public class AttachIsoCmd extends BaseAsyncCmd {
     public long getEntityOwnerId() {
         UserVm vm = _entityMgr.findById(UserVm.class, getVirtualMachineId());
         if (vm == null) {
-            throw new InvalidParameterValueException("Unable to find virtual machine by id " + getVirtualMachineId());
+            throw new InvalidParameterValueException("Unable to find virtual machine by ID " + getVirtualMachineId());
         }
 
         return vm.getAccountId();
@@ -91,12 +91,12 @@ public class AttachIsoCmd extends BaseAsyncCmd {
 
     @Override
     public String getEventDescription() {
-        return  "attaching ISO: " + getId() + " to vm: " + getVirtualMachineId();
+        return  "attaching ISO: " + getId() + " to VM: " + getVirtualMachineId();
     }
 
     @Override
     public void execute() {
-        CallContext.current().setEventDetails("Vm Id: " + getVirtualMachineId() + " ISO Id: " + getId());
+        CallContext.current().setEventDetails("Vm Id: " + getVirtualMachineId() + " ISO ID: " + getId());
         boolean result = _templateService.attachIso(id, virtualMachineId);
         if (result) {
             UserVm userVm = _responseGenerator.findUserVmById(virtualMachineId);
@@ -105,10 +105,10 @@ public class AttachIsoCmd extends BaseAsyncCmd {
                 response.setResponseName(DeployVMCmd.getResultObjectName());
                 setResponseObject(response);
             } else {
-                throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to attach iso");
+                throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to attach ISO");
             }
         } else {
-            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to attach iso");
+            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to attach ISO");
         }
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/CopyIsoCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/CopyIsoCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/CopyIsoCmd.java
index 9002624..b7c13ce 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/CopyIsoCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/CopyIsoCmd.java
@@ -23,7 +23,7 @@ import org.apache.cloudstack.api.ResponseObject.ResponseView;
 import org.apache.cloudstack.api.command.user.template.CopyTemplateCmd;
 import org.apache.cloudstack.api.response.TemplateResponse;
 
-@APICommand(name = "copyIso", description = "Copies an iso from one zone to another.", responseObject = TemplateResponse.class, responseView = ResponseView.Restricted,
+@APICommand(name = "copyIso", description = "Copies an ISO from one zone to another.", responseObject = TemplateResponse.class, responseView = ResponseView.Restricted,
         requestHasSensitiveInfo = false, responseHasSensitiveInfo = false)
 public class CopyIsoCmd extends CopyTemplateCmd {
     public static final Logger s_logger = Logger.getLogger(CopyIsoCmd.class.getName());

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/DeleteIsoCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/DeleteIsoCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/DeleteIsoCmd.java
index 6101e9f..103e922 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/DeleteIsoCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/DeleteIsoCmd.java
@@ -95,7 +95,7 @@ public class DeleteIsoCmd extends BaseAsyncCmd {
 
     @Override
     public String getEventDescription() {
-        return "Deleting iso " + getId();
+        return "Deleting ISO " + getId();
     }
 
     @Override
@@ -116,7 +116,7 @@ public class DeleteIsoCmd extends BaseAsyncCmd {
             SuccessResponse response = new SuccessResponse(getCommandName());
             this.setResponseObject(response);
         } else {
-            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to delete iso");
+            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to delete ISO");
         }
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/DetachIsoCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/DetachIsoCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/DetachIsoCmd.java
index 97db2f3..9ee8ef5 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/DetachIsoCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/DetachIsoCmd.java
@@ -70,7 +70,7 @@ public class DetachIsoCmd extends BaseAsyncCmd {
         if (vm != null) {
             return vm.getAccountId();
         } else {
-            throw new InvalidParameterValueException("Unable to find vm by id " + getVirtualMachineId());
+            throw new InvalidParameterValueException("Unable to find VM by ID " + getVirtualMachineId());
         }
     }
 
@@ -81,7 +81,7 @@ public class DetachIsoCmd extends BaseAsyncCmd {
 
     @Override
     public String getEventDescription() {
-        return  "detaching ISO from vm: " + getVirtualMachineId();
+        return  "detaching ISO from VM: " + getVirtualMachineId();
     }
 
     @Override
@@ -93,7 +93,7 @@ public class DetachIsoCmd extends BaseAsyncCmd {
             response.setResponseName(DeployVMCmd.getResultObjectName());
             setResponseObject(response);
         } else {
-            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to detach iso");
+            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to detach ISO");
         }
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/ExtractIsoCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/ExtractIsoCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/ExtractIsoCmd.java
index b78a3d3..85f6008 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/ExtractIsoCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/ExtractIsoCmd.java
@@ -49,7 +49,7 @@ public class ExtractIsoCmd extends BaseAsyncCmd {
     @Parameter(name = ApiConstants.ID, type = CommandType.UUID, entityType = TemplateResponse.class, required = true, description = "the ID of the ISO file")
     private Long id;
 
-    @Parameter(name = ApiConstants.URL, type = CommandType.STRING, required = false, description = "the url to which the ISO would be extracted")
+    @Parameter(name = ApiConstants.URL, type = CommandType.STRING, required = false, description = "the URL to which the ISO would be extracted")
     private String url;
 
     @Parameter(name = ApiConstants.ZONE_ID,
@@ -109,7 +109,7 @@ public class ExtractIsoCmd extends BaseAsyncCmd {
 
     @Override
     public String getEventDescription() {
-        return "extracting iso: " + getId() + " from zone: " + getZoneId();
+        return "extracting ISO: " + getId() + " from zone: " + getZoneId();
     }
 
     public static String getStaticName() {
@@ -137,7 +137,7 @@ public class ExtractIsoCmd extends BaseAsyncCmd {
                 response.setObjectName("iso");
                 this.setResponseObject(response);
             } else {
-                throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to extract iso");
+                throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to extract ISO");
             }
         } catch (InternalErrorException ex) {
             s_logger.warn("Exception: ", ex);

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/ListIsoPermissionsCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/ListIsoPermissionsCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/ListIsoPermissionsCmd.java
index f8863d1..9a3db43 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/ListIsoPermissionsCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/ListIsoPermissionsCmd.java
@@ -26,7 +26,7 @@ import org.apache.cloudstack.api.response.TemplatePermissionsResponse;
 import com.cloud.storage.Storage.ImageFormat;
 import com.cloud.template.VirtualMachineTemplate;
 
-@APICommand(name = "listIsoPermissions", description = "List iso visibility and all accounts that have permissions to view this iso.", responseObject = TemplatePermissionsResponse.class, responseView = ResponseView.Restricted,
+@APICommand(name = "listIsoPermissions", description = "List ISO visibility and all accounts that have permissions to view this ISO.", responseObject = TemplatePermissionsResponse.class, responseView = ResponseView.Restricted,
             requestHasSensitiveInfo = false,
             responseHasSensitiveInfo = false)
 public class ListIsoPermissionsCmd extends BaseListTemplateOrIsoPermissionsCmd {

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/ListIsosCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/ListIsosCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/ListIsosCmd.java
index 88e4326..dee60f4 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/ListIsosCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/ListIsosCmd.java
@@ -49,7 +49,7 @@ public class ListIsosCmd extends BaseListTaggedResourcesCmd {
     @Parameter(name = ApiConstants.HYPERVISOR, type = CommandType.STRING, description = "the hypervisor for which to restrict the search")
     private String hypervisor;
 
-    @Parameter(name = ApiConstants.ID, type = CommandType.UUID, entityType = TemplateResponse.class, description = "list ISO by id")
+    @Parameter(name = ApiConstants.ID, type = CommandType.UUID, entityType = TemplateResponse.class, description = "list ISO by ID")
     private Long id;
 
     @Parameter(name = ApiConstants.IS_PUBLIC, type = CommandType.BOOLEAN, description = "true if the ISO is publicly available to all users, false otherwise.")
@@ -69,7 +69,7 @@ public class ListIsosCmd extends BaseListTaggedResourcesCmd {
                    + "* community : templates that have been marked as public but not featured. " + "* all : all templates (only usable by admins).")
     private String isoFilter = TemplateFilter.selfexecutable.toString();
 
-    @Parameter(name = ApiConstants.NAME, type = CommandType.STRING, description = "list all isos by name")
+    @Parameter(name = ApiConstants.NAME, type = CommandType.STRING, description = "list all ISOs by name")
     private String isoName;
 
     @Parameter(name = ApiConstants.ZONE_ID, type = CommandType.UUID, entityType = ZoneResponse.class, description = "the ID of the zone")

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/RegisterIsoCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/RegisterIsoCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/RegisterIsoCmd.java
index 453b4b6..a1cb478 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/RegisterIsoCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/RegisterIsoCmd.java
@@ -66,7 +66,7 @@ public class RegisterIsoCmd extends BaseCmd {
                description = "true if you want to register the ISO to be publicly available to all users, false otherwise.")
     private Boolean publicIso;
 
-    @Parameter(name = ApiConstants.IS_EXTRACTABLE, type = CommandType.BOOLEAN, description = "true if the iso or its derivatives are extractable; default is false")
+    @Parameter(name = ApiConstants.IS_EXTRACTABLE, type = CommandType.BOOLEAN, description = "true if the ISO or its derivatives are extractable; default is false")
     private Boolean extractable;
 
     @Parameter(name = ApiConstants.NAME, type = CommandType.STRING, required = true, description = "the name of the ISO")
@@ -75,7 +75,7 @@ public class RegisterIsoCmd extends BaseCmd {
     @Parameter(name = ApiConstants.OS_TYPE_ID,
                type = CommandType.UUID,
                entityType = GuestOSResponse.class,
-               description = "the ID of the OS Type that best represents the OS of this ISO. If the iso is bootable this parameter needs to be passed")
+               description = "the ID of the OS type that best represents the OS of this ISO. If the ISO is bootable this parameter needs to be passed")
     private Long osTypeId;
 
     @Parameter(name = ApiConstants.URL, type = CommandType.STRING, required = true, description = "the URL to where the ISO is currently being hosted")
@@ -97,15 +97,15 @@ public class RegisterIsoCmd extends BaseCmd {
     @Parameter(name = ApiConstants.CHECKSUM, type = CommandType.STRING, description = "the MD5 checksum value of this ISO")
     private String checksum;
 
-    @Parameter(name = ApiConstants.PROJECT_ID, type = CommandType.UUID, entityType = ProjectResponse.class, description = "Register iso for the project")
+    @Parameter(name = ApiConstants.PROJECT_ID, type = CommandType.UUID, entityType = ProjectResponse.class, description = "Register ISO for the project")
     private Long projectId;
 
-    @Parameter(name = ApiConstants.IMAGE_STORE_UUID, type = CommandType.STRING, description = "Image store uuid")
+    @Parameter(name = ApiConstants.IMAGE_STORE_UUID, type = CommandType.STRING, description = "Image store UUID")
     private String imageStoreUuid;
 
     @Parameter(name = ApiConstants.IS_DYNAMICALLY_SCALABLE,
                type = CommandType.BOOLEAN,
-               description = "true if iso contains XS/VMWare tools inorder to support dynamic scaling of VM cpu/memory")
+               description = "true if ISO contains XS/VMWare tools inorder to support dynamic scaling of VM CPU/memory")
     protected Boolean isDynamicallyScalable;
 
     /////////////////////////////////////////////////////
@@ -197,7 +197,7 @@ public class RegisterIsoCmd extends BaseCmd {
             response.setResponseName(getCommandName());
             setResponseObject(response);
         } else {
-            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to register iso");
+            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to register ISO");
         }
 
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoCmd.java
index 5e61160..d072c0a 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoCmd.java
@@ -80,7 +80,7 @@ public class UpdateIsoCmd extends BaseUpdateTemplateOrIsoCmd {
             response.setResponseName(getCommandName());
             setResponseObject(response);
         } else {
-            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to update iso");
+            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to update ISO");
         }
     }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a1f58c48/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoPermissionsCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoPermissionsCmd.java b/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoPermissionsCmd.java
index b52bc91..dd07faf 100644
--- a/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoPermissionsCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/iso/UpdateIsoPermissionsCmd.java
@@ -25,7 +25,7 @@ import org.apache.cloudstack.api.response.SuccessResponse;
 import com.cloud.template.VirtualMachineTemplate;
 import com.cloud.user.Account;
 
-@APICommand(name = "updateIsoPermissions", description = "Updates iso permissions", responseObject = SuccessResponse.class,
+@APICommand(name = "updateIsoPermissions", description = "Updates ISO permissions", responseObject = SuccessResponse.class,
         requestHasSensitiveInfo = false, responseHasSensitiveInfo = false)
 public class UpdateIsoPermissionsCmd extends BaseUpdateTemplateOrIsoPermissionsCmd {
     @Override