mirror of https://github.com/apache/cloudstack.git
resolving merge conflicts before pushing to the remote repository
This commit is contained in:
commit
0f4a245f0a
|
|
@ -36,22 +36,23 @@ public class AddConfigCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="category", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="category", type=CommandType.STRING, required=true, description="component's category")
|
||||
private String category;
|
||||
|
||||
@Parameter(name="component", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="component", type=CommandType.STRING, required=true, description="the component of the configuration")
|
||||
private String component;
|
||||
|
||||
@Parameter(name="description", type=CommandType.STRING)
|
||||
@Parameter(name="description", type=CommandType.STRING, description="the description of the configuration")
|
||||
private String description;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="instance", type=CommandType.STRING, required=true)
|
||||
private String instance;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the configuration")
|
||||
private String name;
|
||||
|
||||
@Parameter(name="value", type=CommandType.STRING)
|
||||
@Parameter(name="value", type=CommandType.STRING, description="the value of the configuration")
|
||||
private String value;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -53,25 +53,25 @@ public class AddHostCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="clusterid", type=CommandType.LONG)
|
||||
@Parameter(name="clusterid", type=CommandType.LONG, description="the cluster ID for the host")
|
||||
private Long clusterId;
|
||||
|
||||
@Parameter(name="clustername", type=CommandType.STRING)
|
||||
@Parameter(name="clustername", type=CommandType.STRING, description="the cluster name for the host")
|
||||
private String clusterName;
|
||||
|
||||
@Parameter(name="password", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="password", type=CommandType.STRING, required=true, description="the password for the host")
|
||||
private String password;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the Pod ID for the host")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true, description="the host URL")
|
||||
private String url;
|
||||
|
||||
@Parameter(name="username", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="username", type=CommandType.STRING, required=true, description="the username for the host")
|
||||
private String username;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description="the Zone ID for the host")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1,90 +0,0 @@
|
|||
/**
|
||||
* Copyright (C) 2010 Cloud.com, Inc. All rights reserved.
|
||||
*
|
||||
* This software is licensed under the GNU General Public License v3 or later.
|
||||
*
|
||||
* It is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or any later version.
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
package com.cloud.api.commands;
|
||||
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
import com.cloud.api.BaseCmd;
|
||||
import com.cloud.api.BaseCmd.Manager;
|
||||
import com.cloud.api.Implementation;
|
||||
import com.cloud.api.Parameter;
|
||||
|
||||
@Implementation(method="discoverHosts", manager=Manager.AgentManager)
|
||||
public abstract class AddHostOrStorageCmd extends BaseCmd {
|
||||
public static final Logger s_logger = Logger.getLogger(AddHostOrStorageCmd.class.getName());
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="clusterid", type=CommandType.LONG)
|
||||
private Long clusterId;
|
||||
|
||||
@Parameter(name="clustername", type=CommandType.STRING)
|
||||
private String clusterName;
|
||||
|
||||
@Parameter(name="password", type=CommandType.STRING, required=true)
|
||||
private String password;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
private String url;
|
||||
|
||||
@Parameter(name="username", type=CommandType.STRING, required=true)
|
||||
private String username;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
/////////////////// Accessors ///////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
public Long getClusterId() {
|
||||
return clusterId;
|
||||
}
|
||||
|
||||
public String getClusterName() {
|
||||
return clusterName;
|
||||
}
|
||||
|
||||
public String getPassword() {
|
||||
return password;
|
||||
}
|
||||
|
||||
public Long getPodId() {
|
||||
return podId;
|
||||
}
|
||||
|
||||
public String getUrl() {
|
||||
return url;
|
||||
}
|
||||
|
||||
public String getUsername() {
|
||||
return username;
|
||||
}
|
||||
|
||||
public Long getZoneId() {
|
||||
return zoneId;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -48,10 +48,10 @@ public class AddSecondaryStorageCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true, description="the URL for the secondary storage")
|
||||
private String url;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the Zone ID for the secondary storage")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,16 +41,16 @@ public class AssignPortForwardingServiceCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the ID of the port forwarding service to assign to the virtual machine/public IP")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="ids", type=CommandType.LIST, collectionType=CommandType.LONG)
|
||||
@Parameter(name="ids", type=CommandType.LIST, collectionType=CommandType.LONG, description="a comma delimited list of port forwarding service IDs to assign to the virtual machine/public IP")
|
||||
private List<Long> ids;
|
||||
|
||||
@Parameter(name="publicip", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="publicip", type=CommandType.STRING, required=true, description="the public IP address to associate to the port forwarding service")
|
||||
private String publicIp;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true, description="the ID of the virtual machine to assign to the port forwarding service")
|
||||
private Long virtualMachineId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -41,13 +41,13 @@ public class AssignToLoadBalancerRuleCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the load balancer rule")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=false)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=false, description="the ID of the virtual machine that is being assigned to the load balancer rule")
|
||||
private Long virtualMachineId;
|
||||
|
||||
@Parameter(name="virtualmachineids", type=CommandType.LIST, collectionType=CommandType.LONG, required=false)
|
||||
@Parameter(name="virtualmachineids", type=CommandType.LIST, collectionType=CommandType.LONG, required=false, description="the list of IDs of the virtual machine that are being assigned to the load balancer rule(i.e. virtualMachineIds=1,2,3)")
|
||||
private List<Long> virtualMachineIds;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,10 +41,10 @@ public class AttachIsoCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the ISO file")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true, description="the ID of the virtual machine")
|
||||
private Long virtualMachineId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -40,13 +40,23 @@ public class AttachVolumeCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="deviceid", type=CommandType.LONG)
|
||||
@Parameter(name="deviceid", type=CommandType.LONG, description="the ID of the device to map the volume to within the guest OS. " +
|
||||
"If no deviceId is passed in, the next available deviceId will be chosen. " +
|
||||
"Possible values for a Linux OS are:" +
|
||||
"* 1 - /dev/xvdb" +
|
||||
"* 2 - /dev/xvdc" +
|
||||
"* 4 - /dev/xvde" +
|
||||
"* 5 - /dev/xvdf" +
|
||||
"* 6 - /dev/xvdg" +
|
||||
"* 7 - /dev/xvdh" +
|
||||
"* 8 - /dev/xvdi" +
|
||||
"* 9 - /dev/xvdj")
|
||||
private Long deviceId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the disk volume")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true, description=" the ID of the virtual machine")
|
||||
private Long virtualMachineId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -50,33 +50,42 @@ public class AuthorizeNetworkGroupIngressCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="protocol", type=CommandType.STRING)
|
||||
@Parameter(name="protocol", type=CommandType.STRING, description="TCP is default. UDP is the other supported protocol")
|
||||
private String protocol;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="startport", type=CommandType.INTEGER)
|
||||
private Integer startPort;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="endport", type=CommandType.INTEGER)
|
||||
private Integer endPort;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="icmptype", type=CommandType.INTEGER)
|
||||
private Integer icmpType;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="icmpcode", type=CommandType.INTEGER)
|
||||
private Integer icmpCode;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="networkgroupname", type=CommandType.STRING, required=true)
|
||||
private String networkGroupName;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="cidrlist", type=CommandType.LIST, collectionType=CommandType.STRING)
|
||||
private List<String> cidrList;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="usernetworkgrouplist", type=CommandType.MAP)
|
||||
private Map userNetworkGroupList;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
private String accountName;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
private Long domainId;
|
||||
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ public class CancelMaintenanceCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the host ID")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ public class CancelPrimaryStorageMaintenanceCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the primary storage ID")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -45,13 +45,13 @@ public class CopyIsoCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="destzoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="destzoneid", type=CommandType.LONG, required=true, description="the ID of the destination zone to which the ISO file will be copied")
|
||||
private Long destZoneId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the ISO file")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="sourcezoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="sourcezoneid", type=CommandType.LONG, required=true, description="the ID of the source zone from which the ISO file will be copied")
|
||||
private Long sourceZoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -45,13 +45,13 @@ public class CopyTemplateCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="destzoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="destzoneid", type=CommandType.LONG, required=true, description="ID of the zone the template is being copied to.")
|
||||
private Long destZoneId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="Template ID.")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="sourcezoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="sourcezoneid", type=CommandType.LONG, required=true, description="ID of the zone the template is currently hosted on.")
|
||||
private Long sourceZoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -38,19 +38,19 @@ public class CreateDiskOfferingCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="disksize", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="disksize", type=CommandType.LONG, required=true, description="disk size of the disk offering in GB")
|
||||
private Long diskSize;
|
||||
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true, description="alternate display text of the disk offering")
|
||||
private String displayText;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="domain ID where disk offering is going to be created")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="name of the disk offering")
|
||||
private String offeringName;
|
||||
|
||||
@Parameter(name="tags", type=CommandType.STRING)
|
||||
@Parameter(name="tags", type=CommandType.STRING, description="tags for the disk offering")
|
||||
private String tags;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -38,22 +38,22 @@ public class CreateLoadBalancerRuleCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="algorithm", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="algorithm", type=CommandType.STRING, required=true, description="load balancer algorithm (source, roundrobin, leastconn)")
|
||||
private String algorithm;
|
||||
|
||||
@Parameter(name="description", type=CommandType.STRING)
|
||||
@Parameter(name="description", type=CommandType.STRING, description="the description of the load balancer rule")
|
||||
private String description;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="name of the load balancer rule")
|
||||
private String loadBalancerRuleName;
|
||||
|
||||
@Parameter(name="privateport", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="privateport", type=CommandType.STRING, required=true, description="the private port of the private ip address/virtual machine where the network traffic will be load balanced to")
|
||||
private String privatePort;
|
||||
|
||||
@Parameter(name="publicip", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="publicip", type=CommandType.STRING, required=true, description="public ip address from where the network traffic will be load balanced from")
|
||||
private String publicIp;
|
||||
|
||||
@Parameter(name="publicport", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="publicport", type=CommandType.STRING, required=true, description="the public port from where the network traffic will be load balanced from")
|
||||
private String publicPort;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ import com.cloud.api.Parameter;
|
|||
import com.cloud.api.response.NetworkGroupResponse;
|
||||
import com.cloud.network.security.NetworkGroupVO;
|
||||
|
||||
@Implementation(method="createLoadBalancerRule", manager=Manager.NetworkGroupManager)
|
||||
@Implementation(method="createNetworkGroup", manager=Manager.NetworkGroupManager)
|
||||
public class CreateNetworkGroupCmd extends BaseCmd {
|
||||
public static final Logger s_logger = Logger.getLogger(CreateNetworkGroupCmd.class.getName());
|
||||
|
||||
|
|
@ -37,16 +37,16 @@ public class CreateNetworkGroupCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="an optional account for the network group. Must be used with domainId.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="description", type=CommandType.STRING)
|
||||
@Parameter(name="description", type=CommandType.STRING, description="the description of the network group")
|
||||
private String description;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="an optional domainId for the network group. If the account parameter is used, domainId must also be used.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="name of the network group")
|
||||
private String networkGroupName;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -38,22 +38,22 @@ public class CreatePodCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="cidr", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="cidr", type=CommandType.STRING, required=true, description="the CIDR notation for the base IP address of the Pod")
|
||||
private String cidr;
|
||||
|
||||
@Parameter(name="endip", type=CommandType.STRING)
|
||||
@Parameter(name="endip", type=CommandType.STRING, description="the ending IP address for the Pod")
|
||||
private String endIp;
|
||||
|
||||
@Parameter(name="gateway", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="gateway", type=CommandType.STRING, required=true, description="the gateway for the Pod")
|
||||
private String gateway;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the Pod")
|
||||
private String podName;
|
||||
|
||||
@Parameter(name="startip", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="startip", type=CommandType.STRING, required=true, description="the starting IP address for the Pod")
|
||||
private String startIp;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description="the Zone ID in which the Pod will be created ")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -40,16 +40,16 @@ public class CreatePortForwardingServiceRuleCmd extends BaseAsyncCreateCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="portforwardingserviceid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="portforwardingserviceid", type=CommandType.LONG, required=true, description="the ID of the port forwarding service the rule is being created for")
|
||||
private Long portForwardingServiceId;
|
||||
|
||||
@Parameter(name="privateport", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="privateport", type=CommandType.STRING, required=true, description="the port of the private ip address/virtual machine to forward traffic to")
|
||||
private String privatePort;
|
||||
|
||||
@Parameter(name="protocol", type=CommandType.STRING)
|
||||
@Parameter(name="protocol", type=CommandType.STRING, description="TCP is default. UDP is the other supported protocol")
|
||||
private String protocol;
|
||||
|
||||
@Parameter(name="publicport", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="publicport", type=CommandType.STRING, required=true, description="the port of the public ip address to forward traffic from")
|
||||
private String publicPort;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -36,31 +36,31 @@ public class CreateServiceOfferingCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="cpunumber", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="cpunumber", type=CommandType.LONG, required=true, description="the CPU number of the service offering")
|
||||
private Long cpuNumber;
|
||||
|
||||
@Parameter(name="cpuspeed", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="cpuspeed", type=CommandType.LONG, required=true, description="the CPU speed of the service offering in MHz.")
|
||||
private Long cpuSpeed;
|
||||
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true, description="the display text of the service offering")
|
||||
private String displayText;
|
||||
|
||||
@Parameter(name="memory", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="memory", type=CommandType.LONG, required=true, description="the total memory of the service offering in MB")
|
||||
private Long memory;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the service offering")
|
||||
private String serviceOfferingName;
|
||||
|
||||
@Parameter(name="offerha", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="offerha", type=CommandType.BOOLEAN, description="the HA for the service offering")
|
||||
private Boolean offerHa;
|
||||
|
||||
@Parameter(name="storagetype", type=CommandType.STRING)
|
||||
@Parameter(name="storagetype", type=CommandType.STRING, description="the storage type of the service offering. Values are local and shared.")
|
||||
private String storageType;
|
||||
|
||||
@Parameter(name="tags", type=CommandType.STRING)
|
||||
@Parameter(name="tags", type=CommandType.STRING, description="the tags for this service offering.")
|
||||
private String tags;
|
||||
|
||||
@Parameter(name="usevirtualnetwork", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="usevirtualnetwork", type=CommandType.BOOLEAN, description="if true, the VM created will use default virtual networking. If false, the VM created will use a direct attached networking model. The default value is true.")
|
||||
private Boolean useVirtualNetwork;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,13 +41,13 @@ public class CreateSnapshotCmd extends BaseAsyncCreateCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="The account of the snapshot. The account parameter must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="The domain ID of the snapshot. If used with the account parameter, specifies a domain for the account associated with the disk volume.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true, description="The ID of the disk volume")
|
||||
private Long volumeId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -37,25 +37,30 @@ public class CreateSnapshotPolicyCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="The account of the snapshot policy. The account parameter must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="The domain ID of the snapshot. If used with the account parameter, specifies a domain for the account associated with the snapshot policy.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="intervaltype", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="intervaltype", type=CommandType.STRING, required=true, description="valid values are HOURLY, DAILY, WEEKLY, and MONTHLY")
|
||||
private String intervalType;
|
||||
|
||||
@Parameter(name="maxsnaps", type=CommandType.INTEGER, required=true)
|
||||
@Parameter(name="maxsnaps", type=CommandType.INTEGER, required=true, description="maximum number of snapshots to retain")
|
||||
private Integer maxSnaps;
|
||||
|
||||
@Parameter(name="schedule", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="schedule", type=CommandType.STRING, required=true, description="time the snapshot is scheduled to be taken. " +
|
||||
"Format is:" +
|
||||
"* if HOURLY, MM" +
|
||||
"* if DAILY, MM:HH" +
|
||||
"* if WEEKLY, MM:HH:DD (1-7)" +
|
||||
"* if MONTHLY, MM:HH:DD (1-28)")
|
||||
private String schedule;
|
||||
|
||||
@Parameter(name="timezone", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="timezone", type=CommandType.STRING, required=true, description="Specifies a timezone for this command. For more information on the timezone parameter, see Time Zone Format.")
|
||||
private String timezone;
|
||||
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true, description="the ID of the disk volume")
|
||||
private Long volumeId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -42,25 +42,25 @@ public class CreateStoragePoolCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="clusterid", type=CommandType.LONG)
|
||||
@Parameter(name="clusterid", type=CommandType.LONG, description="the cluster ID for the storage pool")
|
||||
private Long clusterId;
|
||||
|
||||
@Parameter(name="details", type=CommandType.MAP)
|
||||
@Parameter(name="details", type=CommandType.MAP, description="the details for the storage pool")
|
||||
private Map details;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name for the storage pool")
|
||||
private String storagePoolName;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the Pod ID for the storage pool")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="tags", type=CommandType.STRING)
|
||||
@Parameter(name="tags", type=CommandType.STRING, description="the tags for the storage pool")
|
||||
private String tags;
|
||||
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true, description="the URL of the storage pool")
|
||||
private String url;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description="the Zone ID for the storage pool")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -50,31 +50,31 @@ public class CreateTemplateCmd extends BaseAsyncCreateCmd {
|
|||
@Parameter(name="bits", type=CommandType.INTEGER)
|
||||
private Integer bits;
|
||||
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true, description="the display text of the template. This is usually used for display purposes.")
|
||||
private String displayText;
|
||||
|
||||
@Parameter(name="isfeatured", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="isfeatured", type=CommandType.BOOLEAN, description="true if this template is a featured template, false otherwise")
|
||||
private Boolean featured;
|
||||
|
||||
@Parameter(name="ispublic", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="ispublic", type=CommandType.BOOLEAN, description="true if this template is a public template, false otherwise")
|
||||
private Boolean publicTemplate;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the template")
|
||||
private String templateName;
|
||||
|
||||
@Parameter(name="ostypeid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="ostypeid", type=CommandType.LONG, required=true, description=" the ID of the OS Type that best represents the OS of this template.")
|
||||
private Long osTypeId;
|
||||
|
||||
@Parameter(name="passwordenabled", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="passwordenabled", type=CommandType.BOOLEAN, description="true if the template supports the password reset feature; default is false")
|
||||
private Boolean passwordEnabled;
|
||||
|
||||
@Parameter(name="requireshvm", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="requireshvm", type=CommandType.BOOLEAN, description="true if the template requres HVM, false otherwise")
|
||||
private Boolean requiresHvm;
|
||||
|
||||
@Parameter(name="snapshotid", type=CommandType.LONG)
|
||||
@Parameter(name="snapshotid", type=CommandType.LONG, description="the ID of the snapshot the template is being created from")
|
||||
private Long snapshotId;
|
||||
|
||||
@Parameter(name="volumeid", type=CommandType.LONG)
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, description="the ID of the disk volume the template is being created from")
|
||||
private Long volumeId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -38,13 +38,13 @@ public class CreateVMGroupCmd extends BaseCmd{
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the instance group")
|
||||
private String groupName;
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account of the instance group. The account parameter must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID of account owning the instance group")
|
||||
private Long domainId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -38,34 +38,34 @@ public class CreateVlanIpRangeCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="account who will own the VLAN. If VLAN is Zone wide, this parameter should be ommited")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="domain ID of the account owning a VLAN")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="endip", type=CommandType.STRING)
|
||||
@Parameter(name="endip", type=CommandType.STRING, description="the ending IP address in the VLAN IP range")
|
||||
private String endIp;
|
||||
|
||||
@Parameter(name="forvirtualnetwork", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="forvirtualnetwork", type=CommandType.BOOLEAN, description="true if VLAN is of Virtual type, false if Direct")
|
||||
private Boolean forVirtualNetwork;
|
||||
|
||||
@Parameter(name="gateway", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="gateway", type=CommandType.STRING, required=true, description="the gateway of the VLAN IP range")
|
||||
private String gateway;
|
||||
|
||||
@Parameter(name="netmask", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="netmask", type=CommandType.STRING, required=true, description="the netmask of the VLAN IP range")
|
||||
private String netmask;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="optional parameter. Have to be specified for Direct Untagged vlan only.")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="startip", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="startip", type=CommandType.STRING, required=true, description="the beginning IP address in the VLAN IP range")
|
||||
private String startIp;
|
||||
|
||||
@Parameter(name="vlan", type=CommandType.STRING)
|
||||
@Parameter(name="vlan", type=CommandType.STRING, description="the ID or VID of the VLAN. Default is an \"untagged\" VLAN.")
|
||||
private String vlan;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description=" the Zone ID of the VLAN IP range")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -42,25 +42,25 @@ public class CreateVolumeCmd extends BaseAsyncCreateCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account associated with the disk volume. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="diskofferingid", type=CommandType.LONG)
|
||||
@Parameter(name="diskofferingid", type=CommandType.LONG, description="the ID of the disk offering. Either diskOfferingId or snapshotId must be passed in.")
|
||||
private Long diskOfferingId;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID associated with the disk offering. If used with the account parameter returns the disk volume associated with the account for the specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the disk volume")
|
||||
private String volumeName;
|
||||
|
||||
@Parameter(name="size", type=CommandType.LONG)
|
||||
@Parameter(name="size", type=CommandType.LONG, description="Arbitrary volume size. Mutually exclusive with diskOfferingId")
|
||||
private Long size;
|
||||
|
||||
@Parameter(name="snapshotid", type=CommandType.LONG)
|
||||
@Parameter(name="snapshotid", type=CommandType.LONG, description="the snapshot ID for the disk volume. Either diskOfferingId or snapshotId must be passed in.")
|
||||
private Long snapshotId;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the ID of the availability zone")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -37,25 +37,26 @@ public class CreateZoneCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="dns1", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="dns1", type=CommandType.STRING, required=true, description="the first DNS for the Zone")
|
||||
private String dns1;
|
||||
|
||||
@Parameter(name="dns2", type=CommandType.STRING)
|
||||
@Parameter(name="dns2", type=CommandType.STRING, description="the second DNS for the Zone")
|
||||
private String dns2;
|
||||
|
||||
@Parameter(name="guestcidraddress", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="guestcidraddress", type=CommandType.STRING, required=true, description="the guest CIDR address for the Zone")
|
||||
private String guestCidrAddress;
|
||||
|
||||
@Parameter(name="internaldns1", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="internaldns1", type=CommandType.STRING, required=true, description="the first internal DNS for the Zone")
|
||||
private String internalDns1;
|
||||
|
||||
@Parameter(name="internaldns2", type=CommandType.STRING)
|
||||
@Parameter(name="internaldns2", type=CommandType.STRING, description="the second internal DNS for the Zone")
|
||||
private String internalDns2;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the Zone")
|
||||
private String zoneName;
|
||||
|
||||
@Parameter(name="vlan", type=CommandType.STRING)
|
||||
|
||||
//FIXME - this parameter is called "vnet" in updateZone. Have to figure out which one is right
|
||||
@Parameter(name="vlan", type=CommandType.STRING, description="the VNET for the Zone")
|
||||
private String vlan;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ public class DeleteDiskOfferingCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="ID of the disk offering")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -21,9 +21,11 @@ import org.apache.log4j.Logger;
|
|||
|
||||
import com.cloud.api.ApiDBUtils;
|
||||
import com.cloud.api.BaseAsyncCmd;
|
||||
import com.cloud.api.BaseCmd;
|
||||
import com.cloud.api.Implementation;
|
||||
import com.cloud.api.Parameter;
|
||||
import com.cloud.api.response.DeleteDomainResponse;
|
||||
import com.cloud.api.ServerApiException;
|
||||
import com.cloud.api.response.SuccessResponse;
|
||||
import com.cloud.domain.DomainVO;
|
||||
import com.cloud.event.EventTypes;
|
||||
import com.cloud.user.Account;
|
||||
|
|
@ -86,11 +88,16 @@ public class DeleteDomainCmd extends BaseAsyncCmd {
|
|||
}
|
||||
|
||||
@Override @SuppressWarnings("unchecked")
|
||||
public DeleteDomainResponse getResponse() {
|
||||
String deleteResult = (String)getResponseObject();
|
||||
public SuccessResponse getResponse() {
|
||||
Boolean responseObject = (Boolean)getResponseObject();
|
||||
|
||||
DeleteDomainResponse response = new DeleteDomainResponse();
|
||||
response.setResult(deleteResult);
|
||||
SuccessResponse response = new SuccessResponse();
|
||||
|
||||
if (responseObject != null) {
|
||||
response.setSuccess(responseObject);
|
||||
} else {
|
||||
throw new ServerApiException(BaseCmd.INTERNAL_ERROR, "Failed to delete host");
|
||||
}
|
||||
|
||||
response.setResponseName(getName());
|
||||
return response;
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ public class DeleteHostCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the host ID")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -40,10 +40,10 @@ public class DeleteIsoCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the ISO file")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the ID of the zone of the ISO file. If not specified, the ISO will be deleted from all the zones")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public class DeleteLoadBalancerRuleCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the load balancer rule")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -17,13 +17,13 @@ public class DeleteNetworkGroupCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account of the network group. Must be specified with domain ID")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID of account owning the network group")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the network group name")
|
||||
private String networkGroupName;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public class DeletePodCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the Pod")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ public class DeletePoolCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="Storage pool id")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ public class DeletePortForwardingServiceCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="ID of the port forwarding service")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ package com.cloud.api.commands;
|
|||
import com.cloud.api.BaseCmd;
|
||||
import com.cloud.api.Implementation;
|
||||
import com.cloud.api.Parameter;
|
||||
import com.cloud.api.response.DeletePreallocatedLunResponse;
|
||||
import com.cloud.api.response.SuccessResponse;
|
||||
|
||||
@Implementation(method="unregisterPreallocatedLun")
|
||||
public class DeletePreallocatedLunCmd extends BaseCmd {
|
||||
|
|
@ -30,7 +30,7 @@ public class DeletePreallocatedLunCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="preallocated LUN ID")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
@ -51,10 +51,10 @@ public class DeletePreallocatedLunCmd extends BaseCmd {
|
|||
}
|
||||
|
||||
@Override @SuppressWarnings("unchecked")
|
||||
public DeletePreallocatedLunResponse getResponse() {
|
||||
public SuccessResponse getResponse() {
|
||||
Boolean result = (Boolean)getResponseObject();
|
||||
|
||||
DeletePreallocatedLunResponse response = new DeletePreallocatedLunResponse();
|
||||
SuccessResponse response = new SuccessResponse();
|
||||
response.setSuccess(result);
|
||||
|
||||
response.setResponseName(getName());
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ public class DeleteServiceOfferingCmd extends BaseCmd{
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the service offering")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ public class DeleteSnapshotCmd extends BaseAsyncCmd {
|
|||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="The ID of the snapshot")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -44,10 +44,10 @@ public class DeleteSnapshotPoliciesCmd extends BaseCmd {
|
|||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the Id of the snapshot")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="ids", type=CommandType.LIST, collectionType=CommandType.LONG)
|
||||
@Parameter(name="ids", type=CommandType.LIST, collectionType=CommandType.LONG, description="list of snapshots IDs separated by comma")
|
||||
private List<Long> ids;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -39,10 +39,10 @@ public class DeleteTemplateCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the template")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the ID of zone of the template")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ public class DeleteVMGroupCmd extends BaseCmd{
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the instance group")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ public class DeleteVlanIpRangeCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the id of the VLAN IP range")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ public class DeleteVolumeCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="The ID of the disk volume")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ public class DeleteZoneCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the Zone")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -47,40 +47,40 @@ public class DeployVMCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="an optional account for the virtual machine. Must be used with domainId.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="diskofferingid", type=CommandType.LONG)
|
||||
@Parameter(name="diskofferingid", type=CommandType.LONG, description="the ID of the disk offering for the virtual machine. If the template is of ISO format, the diskOfferingId is for the root disk volume. Otherwise this parameter is used to dinidcate the offering for the data disk volume. If the templateId parameter passed is from a Template object, the diskOfferingId refers to a DATA Disk Volume created. If the templateId parameter passed is from an ISO object, the diskOfferingId refers to a ROOT Disk Volume created.")
|
||||
private Long diskOfferingId;
|
||||
|
||||
@Parameter(name="displayname", type=CommandType.STRING)
|
||||
@Parameter(name="displayname", type=CommandType.STRING, description="an optional user generated name for the virtual machine")
|
||||
private String displayName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="an optional domainId for the virtual machine. If the account parameter is used, domainId must also be used.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="group", type=CommandType.STRING)
|
||||
@Parameter(name="group", type=CommandType.STRING, description="an optional group for the virtual machine")
|
||||
private String group;
|
||||
|
||||
@Parameter(name="hypervisor", type=CommandType.STRING)
|
||||
@Parameter(name="hypervisor", type=CommandType.STRING, description="the hypervisor on which to deploy the virtual machine")
|
||||
private String hypervisor;
|
||||
|
||||
@Parameter(name="networkgrouplist", type=CommandType.LIST, collectionType=CommandType.STRING)
|
||||
@Parameter(name="networkgrouplist", type=CommandType.LIST, collectionType=CommandType.STRING, description="comma separated list of network groups that going to be applied to the virtual machine. Should be passed only when vm is created from service offering with Direct Attach Network support")
|
||||
private List<String> networkGroupList;
|
||||
|
||||
@Parameter(name="serviceofferingid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="serviceofferingid", type=CommandType.LONG, required=true, description="the ID of the service offering for the virtual machine")
|
||||
private Long serviceOfferingId;
|
||||
|
||||
@Parameter(name="size", type=CommandType.LONG)
|
||||
@Parameter(name="size", type=CommandType.LONG, description="the arbitrary size for the DATADISK volume. Mutually exclusive with diskOfferingId")
|
||||
private Long size;
|
||||
|
||||
@Parameter(name="templateid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="templateid", type=CommandType.LONG, required=true, description="the ID of the template for the virtual machine")
|
||||
private Long templateId;
|
||||
|
||||
@Parameter(name="userdata", type=CommandType.STRING)
|
||||
@Parameter(name="userdata", type=CommandType.STRING, description="an optional binary data that can be sent to the virtual machine upon a successful deployment. This binary data must be base64 encoded before adding it to the request. Currently only HTTP GET is supported. Using HTTP GET (via querystring), you can send up to 2KB of data after base64 encoding.")
|
||||
private String userData;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description="availability zone for the virtual machine")
|
||||
private Long zoneId;
|
||||
|
||||
// unexposed parameter needed for serializing/deserializing the command
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ public class DestroyConsoleProxyCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="console proxy ID")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ public class DestroyVMCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="The ID of the virtual machine")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ public class DetachIsoCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, required=true, description=" The ID of the virtual machine")
|
||||
private Long virtualMachineId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -39,13 +39,13 @@ public class DetachVolumeCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the ID of the disk volume")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="deviceid", type=CommandType.LONG)
|
||||
@Parameter(name="deviceid", type=CommandType.LONG, description="the device ID on the virtual machine where volume is detached from")
|
||||
private Long deviceId;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, description="the ID of the virtual machine where the volume is detached from")
|
||||
private Long virtualMachineId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -39,13 +39,14 @@ public class ExtractIsoCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the ISO file")
|
||||
private Long id;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
private String url;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description="the ID of the zone where the ISO is originally located")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -39,12 +39,15 @@ public class ExtractTemplateCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
private Long id;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
private String url;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
private Long zoneId;
|
||||
|
||||
|
|
|
|||
|
|
@ -38,12 +38,15 @@ public class ExtractVolumeCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
private Long id;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
private String url;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
private Long zoneId;
|
||||
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ public class GetCloudIdentifierCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="userid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="userid", type=CommandType.LONG, required=true, description="the user ID for the cloud identifier")
|
||||
private Long userid;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -49,25 +49,25 @@ public class ListAccountsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING, description="List account for a specified account. Must be used with the domainId parameter.")
|
||||
@Parameter(name="account", type=CommandType.STRING, description="list account for a specified account. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="accounttype", type=CommandType.LONG, description="List accounts by account type. Valid account types are 1 (admin), 2 (domain-admin), and 0 (user).")
|
||||
@Parameter(name="accounttype", type=CommandType.LONG, description="list accounts by account type. Valid account types are 1 (admin), 2 (domain-admin), and 0 (user).")
|
||||
private Long accountType;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="List all accounts in specified domain. If used with the account parameter, retrieves account information for specified account in specified domain.")
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="list all accounts in specified domain. If used with the account parameter, retrieves account information for specified account in specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, description="List account by account ID")
|
||||
@Parameter(name="id", type=CommandType.LONG, description="list account by account ID")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="iscleanuprequired", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="iscleanuprequired", type=CommandType.BOOLEAN, description="list accounts by cleanuprequred attribute (values are true or false)")
|
||||
private Boolean cleanupRequired;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, description="List account by account name")
|
||||
@Parameter(name="name", type=CommandType.STRING, description="list account by account name")
|
||||
private String searchName;
|
||||
|
||||
@Parameter(name="state", type=CommandType.STRING, description="List accounts by state. Valid states are enabled, disabled, and locked.")
|
||||
@Parameter(name="state", type=CommandType.STRING, description="list accounts by state. Valid states are enabled, disabled, and locked.")
|
||||
private String state;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ public class ListAlertsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="type", type=CommandType.STRING)
|
||||
@Parameter(name="type", type=CommandType.STRING, description="list by alert type")
|
||||
private String type;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -38,13 +38,13 @@ public class ListAsyncJobsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account associated with the async job. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID associated with the async job. If used with the account parameter, returns async jobs for the account in the specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="startdate", type=CommandType.TZDATE)
|
||||
@Parameter(name="startdate", type=CommandType.TZDATE, description="the start date of the async job")
|
||||
private Date startDate;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -52,16 +52,16 @@ public class ListCapacityCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="hostid", type=CommandType.LONG)
|
||||
@Parameter(name="hostid", type=CommandType.LONG, description="lists capacity by the Host ID")
|
||||
private Long hostId;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="lists capacity by the Pod ID")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="type", type=CommandType.STRING)
|
||||
@Parameter(name="type", type=CommandType.STRING, description="lists capacity by type")
|
||||
private String type;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="lists capacity by the Zone ID")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -40,10 +40,10 @@ public class ListCfgsByCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="category", type=CommandType.STRING)
|
||||
@Parameter(name="category", type=CommandType.STRING, description="lists configurations by category")
|
||||
private String category;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="lists configuration by name")
|
||||
private String configName;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -43,16 +43,16 @@ public class ListClustersCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="lists clusters by the cluster ID")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="lists clusters by the cluster name")
|
||||
private String clusterName;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="lists clusters by Pod ID")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="lists clusters by Zone ID")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -41,13 +41,13 @@ public class ListDiskOfferingsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the ID of the domain of the disk offering. This information is not currently applicable, and should not be used as a parameter.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="ID of the disk offering")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="name of the disk offering")
|
||||
private String diskOfferingName;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -42,28 +42,28 @@ public class ListEventsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account for the event. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID for the event. If used with the account parameter, returns all events for an account in the specified domain ID.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="duration", type=CommandType.INTEGER)
|
||||
@Parameter(name="duration", type=CommandType.INTEGER, description="the duration of the event")
|
||||
private Integer duration;
|
||||
|
||||
@Parameter(name="enddate", type=CommandType.DATE)
|
||||
@Parameter(name="enddate", type=CommandType.DATE, description="the end date range of the list you want to retrieve (use format \"yyyy-MM-dd\")")
|
||||
private Date endDate;
|
||||
|
||||
@Parameter(name="entrytime", type=CommandType.INTEGER)
|
||||
@Parameter(name="entrytime", type=CommandType.INTEGER, description="the time the event was entered")
|
||||
private Integer entryTime;
|
||||
|
||||
@Parameter(name="level", type=CommandType.STRING)
|
||||
@Parameter(name="level", type=CommandType.STRING, description="the event level (INFO, WARN, ERROR)")
|
||||
private String level;
|
||||
|
||||
@Parameter(name="startdate", type=CommandType.DATE)
|
||||
@Parameter(name="startdate", type=CommandType.DATE, description="the start date range of the list you want to retrieve (use format \"yyyy-MM-dd\")")
|
||||
private Date startDate;
|
||||
|
||||
@Parameter(name="type", type=CommandType.STRING)
|
||||
@Parameter(name="type", type=CommandType.STRING, description="the event type (see event types)")
|
||||
private String type;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ public class ListGuestOsCategoriesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="list Os category by id")
|
||||
private Long id;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -40,10 +40,10 @@ public class ListGuestOsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="list by Os type Id")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="oscategoryid", type=CommandType.LONG)
|
||||
@Parameter(name="oscategoryid", type=CommandType.LONG, description="list by Os Category id")
|
||||
private Long osCategoryId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -52,25 +52,25 @@ public class ListHostsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="clusterid", type=CommandType.LONG)
|
||||
@Parameter(name="clusterid", type=CommandType.LONG, description="lists hosts existing in particular cluster")
|
||||
private Long clusterId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the id of the host")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the name of the host")
|
||||
private String hostName;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the Pod ID for the host")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="state", type=CommandType.STRING)
|
||||
@Parameter(name="state", type=CommandType.STRING, description="the state of the host")
|
||||
private String state;
|
||||
|
||||
@Parameter(name="type", type=CommandType.STRING)
|
||||
@Parameter(name="type", type=CommandType.STRING, description="the host type")
|
||||
private String type;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the Zone ID for the host")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -52,34 +52,38 @@ public class ListIsosCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account of the ISO file. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="bootable", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="bootable", type=CommandType.BOOLEAN, description="true if the ISO is bootable, false otherwise")
|
||||
private Boolean bootable;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="lists all available ISO files by ID of a domain. If used with the account parameter, lists all available ISO files for the account in the ID of a domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="hypervisor", type=CommandType.STRING)
|
||||
@Parameter(name="hypervisor", type=CommandType.STRING, description="the hypervisor for which to restrict the search")
|
||||
private String hypervisor;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="list all isos by id")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="ispublic", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="ispublic", type=CommandType.BOOLEAN, description="true if the ISO is publicly available to all users, false otherwise.")
|
||||
private Boolean publicIso;
|
||||
|
||||
@Parameter(name="isready", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="isready", type=CommandType.BOOLEAN, description="true if this ISO is ready to be deployed")
|
||||
private Boolean ready;
|
||||
|
||||
@Parameter(name="isofilter", type=CommandType.STRING)
|
||||
@Parameter(name="isofilter", type=CommandType.STRING, description="possible values are \"featured\", \"self\", \"self-executable\",\"executable\", and \"community\". " +
|
||||
"* featured—ISOs that are featured and are publicself—ISOs that have been registered/created by the owner. " +
|
||||
"* selfexecutable— ISOs that have been registered/created by the owner that can be used to deploy a new VM. " +
|
||||
"* executable— all ISOs that can be used to deploy a new VM " +
|
||||
"* community—ISOs that are public.")
|
||||
private String isoFilter = TemplateFilter.selfexecutable.toString();
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="list all isos by name")
|
||||
private String isoName;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the ID of the zone")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -41,10 +41,10 @@ public class ListLoadBalancerRuleInstancesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="applied", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="applied", type=CommandType.BOOLEAN, description="true if listing all virtual machines currently applied to the load balancer rule; default is true")
|
||||
private Boolean applied;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the load balancer rule")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -42,22 +42,22 @@ public class ListLoadBalancerRulesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account of the load balancer rule. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID of the load balancer rule. If used with the account parameter, lists load balancer rules for the account in the specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the ID of the load balancer rule")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the name of the load balancer rule")
|
||||
private String loadBalancerRuleName;
|
||||
|
||||
@Parameter(name="publicip", type=CommandType.STRING)
|
||||
@Parameter(name="publicip", type=CommandType.STRING, description="the public IP address of the load balancer rule ")
|
||||
private String publicIp;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, description="the ID of the virtual machine of the load balancer rule")
|
||||
private Long virtualMachineId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -44,16 +44,16 @@ public class ListNetworkGroupsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="lists all available port network groups for the account. Must be used with domainID parameter")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="lists all available network groups for the domain ID. If used with the account parameter, lists all available network groups for the account in the specified domain ID.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="networkgroupname", type=CommandType.STRING)
|
||||
@Parameter(name="networkgroupname", type=CommandType.STRING, description="lists network groups by name")
|
||||
private String networkGroupName;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, description="lists network groups by virtual machine id")
|
||||
private Long virtualMachineId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,13 +41,13 @@ public class ListPodsByCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="list Pods by ID")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="list Pods by name")
|
||||
private String podName;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="list Pods by Zone ID")
|
||||
private Long zoneId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ public class ListPortForwardingRulesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="ipaddress", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="ipaddress", type=CommandType.STRING, required=true, description="the IP address of the port forwarding services")
|
||||
private String ipAddress;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -43,16 +43,16 @@ public class ListPortForwardingServicesByVmCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account associated with the port forwarding services. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID associated with the port forwarding services. If used with the account parameter, returns a list of all port forwarding services for an account in the specified domain ID.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="ipaddress", type=CommandType.STRING)
|
||||
@Parameter(name="ipaddress", type=CommandType.STRING, description="public ip address")
|
||||
private String ipAddress;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, description="ID of the virtual machine")
|
||||
private Long virtualMachineId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -42,16 +42,16 @@ public class ListPortForwardingServicesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="lists all available port forwarding services for the account. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="lists all available port forwarding services for the domain ID. If used with the account parameter, lists all available port forwarding services for the account in the specified domain ID.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the ID of the port forwarding service")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the name of the port forwarding service")
|
||||
private String portForwardingServiceName;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -40,9 +40,11 @@ public class ListPreallocatedLunsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="scope", type=CommandType.STRING)
|
||||
private String scope;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="targetiqn", type=CommandType.STRING)
|
||||
private String targetIqn;
|
||||
|
||||
|
|
|
|||
|
|
@ -37,10 +37,10 @@ public class ListRecurringSnapshotScheduleCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="snapshotpolicyid", type=CommandType.LONG)
|
||||
@Parameter(name="snapshotpolicyid", type=CommandType.LONG, description="lists recurring snapshots by snapshot policy ID")
|
||||
private Long snapshotPolicyId;
|
||||
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true, description="list recurring snapshots by volume ID")
|
||||
private Long volumeId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -43,18 +43,22 @@ public class ListResourceLimitsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="Lists resource limits by account. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="Lists resource limits by domain ID. If used with the account parameter, lists resource limits for a specified account in a specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="Lists resource limits by ID.")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="resourcetype", type=CommandType.INTEGER)
|
||||
private Integer resourceType;
|
||||
|
||||
@Parameter(name="resourcetype", type=CommandType.INTEGER, required=true, description="Type of resource to update. Values are 0, 1, 2, 3, and 4. 0 — Instance. Number of instances a user can create. " +
|
||||
"1 — IP. Number of public IP addresses a user can own. " +
|
||||
"2 — Volume. Number of disk volumes a user can create." +
|
||||
"3 — Snapshot. Number of snapshots a user can create." +
|
||||
"4 — Template. Number of templates that a user can register/create.")
|
||||
private Integer resourceType;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
/////////////////// Accessors ///////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -43,25 +43,25 @@ public class ListRoutersCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the name of the account associated with the router. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID associated with the router. If used with the account parameter, lists all routers associated with an account in the specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="hostid", type=CommandType.LONG)
|
||||
@Parameter(name="hostid", type=CommandType.LONG, description="the host ID of the router")
|
||||
private Long hostId;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the name of the router")
|
||||
private String routerName;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the Pod ID of the router")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="state", type=CommandType.STRING)
|
||||
@Parameter(name="state", type=CommandType.STRING, description="the state of the router")
|
||||
private String state;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the Zone ID of the router")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -40,13 +40,13 @@ public class ListServiceOfferingsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="ID of the service offering")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="name of the service offering")
|
||||
private String serviceOfferingName;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, description="the ID of the virtual machine. Pass this in if you want to see the available service offering that a virtual machine can be changed to.")
|
||||
private Long virtualMachineId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,13 +41,13 @@ public class ListSnapshotPoliciesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="lists snapshot policies for the specified account. Must be used with domainid parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID. If used with the account parameter, lists snapshot policies for the specified account in this domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, required=true, description="the ID of the disk volume")
|
||||
private Long volumeId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -45,25 +45,25 @@ public class ListSnapshotsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="lists snapshot belongig to the specified account. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID. If used with the account parameter, lists snapshots for the specified account in this domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="lists snapshot by snapshot ID")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="intervalType", type=CommandType.STRING)
|
||||
@Parameter(name="intervalType", type=CommandType.STRING, description="valid values are HOURLY, DAILY, WEEKLY, and MONTHLY.")
|
||||
private String intervalType;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="lists snapshot by snapshot name")
|
||||
private String snapshotName;
|
||||
|
||||
@Parameter(name="snapshottype", type=CommandType.STRING)
|
||||
@Parameter(name="snapshottype", type=CommandType.STRING, description="valid values are MANUAL or RECURRING.")
|
||||
private String snapshotType;
|
||||
|
||||
@Parameter(name="volumeid", type=CommandType.LONG)
|
||||
@Parameter(name="volumeid", type=CommandType.LONG, description="the ID of the disk volume")
|
||||
private Long volumeId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -1,276 +0,0 @@
|
|||
/**
|
||||
* Copyright (C) 2010 Cloud.com, Inc. All rights reserved.
|
||||
*
|
||||
* This software is licensed under the GNU General Public License v3 or later.
|
||||
*
|
||||
* It is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or any later version.
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
package com.cloud.api.commands;
|
||||
|
||||
import java.text.DecimalFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
import com.cloud.api.ApiDBUtils;
|
||||
import com.cloud.api.BaseListCmd;
|
||||
import com.cloud.api.Implementation;
|
||||
import com.cloud.api.Parameter;
|
||||
import com.cloud.api.ResponseObject;
|
||||
import com.cloud.api.response.ApiResponseSerializer;
|
||||
import com.cloud.api.response.HostResponse;
|
||||
import com.cloud.api.response.ListResponse;
|
||||
import com.cloud.api.response.StoragePoolResponse;
|
||||
import com.cloud.dc.ClusterVO;
|
||||
import com.cloud.host.Host;
|
||||
import com.cloud.host.HostStats;
|
||||
import com.cloud.host.HostVO;
|
||||
import com.cloud.host.Status.Event;
|
||||
import com.cloud.offering.ServiceOffering;
|
||||
import com.cloud.storage.GuestOSCategoryVO;
|
||||
import com.cloud.storage.StoragePoolVO;
|
||||
import com.cloud.storage.StorageStats;
|
||||
import com.cloud.vm.UserVmVO;
|
||||
|
||||
@Implementation(method="")
|
||||
public class ListStoragePoolsAndHostsCmd extends BaseListCmd {
|
||||
public static final Logger s_logger = Logger.getLogger(ListStoragePoolsAndHostsCmd.class.getName());
|
||||
|
||||
private static final String s_name = "liststoragepoolsandhostsresponse";
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="ipaddress", type=CommandType.STRING)
|
||||
private String ipAddress;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
private String storagePoolName;
|
||||
|
||||
@Parameter(name="path", type=CommandType.STRING)
|
||||
private String path;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="state", type=CommandType.STRING)
|
||||
private String state;
|
||||
|
||||
@Parameter(name="type", type=CommandType.STRING)
|
||||
private String type;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
/////////////////// Accessors ///////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
public String getIpAddress() {
|
||||
return ipAddress;
|
||||
}
|
||||
|
||||
public String getStoragePoolName() {
|
||||
return storagePoolName;
|
||||
}
|
||||
|
||||
public String getPath() {
|
||||
return path;
|
||||
}
|
||||
|
||||
public Long getPodId() {
|
||||
return podId;
|
||||
}
|
||||
|
||||
public String getState() {
|
||||
return state;
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public Long getZoneId() {
|
||||
return zoneId;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
/////////////// API Implementation///////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
return s_name;
|
||||
}
|
||||
|
||||
@Override @SuppressWarnings("unchecked")
|
||||
public ResponseObject getResponse() {
|
||||
List<Object> poolsAndHosts = (List<Object>)getResponseObject();
|
||||
|
||||
ListResponse response = new ListResponse();
|
||||
List<ResponseObject> responses = new ArrayList<ResponseObject>();
|
||||
for (Object poolOrHost : poolsAndHosts) {
|
||||
if (poolOrHost instanceof StoragePoolVO) {
|
||||
StoragePoolVO pool = (StoragePoolVO)poolOrHost;
|
||||
responses.add(constructStoragePoolResponse(pool));
|
||||
} else if (poolOrHost instanceof HostVO) {
|
||||
HostVO host = (HostVO)poolOrHost;
|
||||
responses.add(constructHostResponse(host));
|
||||
}
|
||||
}
|
||||
|
||||
response.setResponses(responses);
|
||||
response.setResponseName(getName());
|
||||
return response;
|
||||
}
|
||||
|
||||
private StoragePoolResponse constructStoragePoolResponse(StoragePoolVO pool) {
|
||||
StoragePoolResponse poolResponse = new StoragePoolResponse();
|
||||
poolResponse.setId(pool.getId());
|
||||
poolResponse.setName(pool.getName());
|
||||
poolResponse.setPath(pool.getPath());
|
||||
poolResponse.setIpAddress(pool.getHostAddress());
|
||||
poolResponse.setZoneId(pool.getDataCenterId());
|
||||
poolResponse.setZoneName(ApiDBUtils.findZoneById(pool.getDataCenterId()).getName());
|
||||
if (pool.getPoolType() != null) {
|
||||
poolResponse.setType(pool.getPoolType().toString());
|
||||
}
|
||||
if (pool.getPodId() != null) {
|
||||
poolResponse.setPodId(pool.getPodId());
|
||||
poolResponse.setPodName(ApiDBUtils.findPodById(pool.getPodId()).getName());
|
||||
}
|
||||
if (pool.getCreated() != null) {
|
||||
poolResponse.setCreated(pool.getCreated());
|
||||
}
|
||||
|
||||
StorageStats stats = ApiDBUtils.getStoragePoolStatistics(pool.getId());
|
||||
long capacity = pool.getCapacityBytes();
|
||||
long available = pool.getAvailableBytes() ;
|
||||
long used = capacity - available;
|
||||
|
||||
if (stats != null) {
|
||||
used = stats.getByteUsed();
|
||||
available = capacity - used;
|
||||
}
|
||||
|
||||
poolResponse.setDiskSizeTotal(pool.getCapacityBytes());
|
||||
poolResponse.setDiskSizeAllocated(used);
|
||||
|
||||
if (pool.getClusterId() != null) {
|
||||
ClusterVO cluster = ApiDBUtils.findClusterById(pool.getClusterId());
|
||||
poolResponse.setClusterId(cluster.getId());
|
||||
poolResponse.setClusterName(cluster.getName());
|
||||
}
|
||||
|
||||
poolResponse.setTags(ApiDBUtils.getStoragePoolTags(pool.getId()));
|
||||
poolResponse.setResponseName("storagepools");
|
||||
|
||||
return poolResponse;
|
||||
}
|
||||
|
||||
private HostResponse constructHostResponse(HostVO host) {
|
||||
HostResponse hostResponse = new HostResponse();
|
||||
hostResponse.setId(host.getId());
|
||||
hostResponse.setCapabilities(host.getCapabilities());
|
||||
hostResponse.setClusterId(host.getClusterId());
|
||||
hostResponse.setCpuNumber(host.getCpus());
|
||||
hostResponse.setZoneId(host.getDataCenterId());
|
||||
hostResponse.setDisconnectedOn(host.getDisconnectedOn());
|
||||
hostResponse.setHypervisor(host.getHypervisorType());
|
||||
hostResponse.setHostType(host.getType());
|
||||
hostResponse.setLastPinged(new Date(host.getLastPinged()));
|
||||
hostResponse.setManagementServerId(host.getManagementServerId());
|
||||
hostResponse.setName(host.getName());
|
||||
hostResponse.setPodId(host.getPodId());
|
||||
hostResponse.setRemoved(host.getRemoved());
|
||||
hostResponse.setCpuSpeed(host.getSpeed());
|
||||
hostResponse.setState(host.getStatus());
|
||||
hostResponse.setIpAddress(host.getPrivateIpAddress());
|
||||
hostResponse.setVersion(host.getVersion());
|
||||
|
||||
// TODO: implement
|
||||
GuestOSCategoryVO guestOSCategory = ApiDBUtils.getHostGuestOSCategory(host.getId());
|
||||
if (guestOSCategory != null) {
|
||||
hostResponse.setOsCategoryId(guestOSCategory.getId());
|
||||
hostResponse.setOsCategoryName(guestOSCategory.getName());
|
||||
}
|
||||
hostResponse.setZoneName(ApiDBUtils.findZoneById(host.getDataCenterId()).getName());
|
||||
hostResponse.setPodName(ApiDBUtils.findPodById(host.getPodId()).getName());
|
||||
|
||||
// calculate cpu allocated by vm
|
||||
int cpu = 0;
|
||||
String cpuAlloc = null;
|
||||
DecimalFormat decimalFormat = new DecimalFormat("#.##");
|
||||
List<UserVmVO> instances = ApiDBUtils.listUserVMsByHostId(host.getId());
|
||||
for (UserVmVO vm : instances) {
|
||||
ServiceOffering so = ApiDBUtils.findServiceOfferingById(vm.getServiceOfferingId());
|
||||
cpu += so.getCpu() * so.getSpeed();
|
||||
}
|
||||
cpuAlloc = decimalFormat.format(((float) cpu / (float) (host.getCpus() * host.getSpeed())) * 100f) + "%";
|
||||
hostResponse.setCpuAllocated(cpuAlloc);
|
||||
|
||||
// calculate cpu utilized
|
||||
String cpuUsed = null;
|
||||
HostStats hostStats = ApiDBUtils.getHostStatistics(host.getId());
|
||||
if (hostStats != null) {
|
||||
float cpuUtil = (float) hostStats.getCpuUtilization();
|
||||
cpuUsed = decimalFormat.format(cpuUtil) + "%";
|
||||
hostResponse.setCpuUsed(cpuUsed);
|
||||
hostResponse.setAverageLoad((long)hostStats.getAverageLoad());
|
||||
hostResponse.setNetworkKbsRead((long)hostStats.getNetworkReadKBs());
|
||||
hostResponse.setNetworkKbsWrite((long)hostStats.getNetworkWriteKBs());
|
||||
}
|
||||
|
||||
if (host.getType() == Host.Type.Routing) {
|
||||
hostResponse.setMemoryTotal(host.getTotalMemory());
|
||||
|
||||
// calculate memory allocated by systemVM and userVm
|
||||
long mem = ApiDBUtils.getMemoryUsagebyHost(host.getId());
|
||||
hostResponse.setMemoryAllocated(mem);
|
||||
hostResponse.setMemoryUsed(mem);
|
||||
} else if (host.getType().toString().equals("Storage")) {
|
||||
hostResponse.setDiskSizeTotal(host.getTotalSize());
|
||||
hostResponse.setDiskSizeAllocated(0L);
|
||||
}
|
||||
|
||||
if (host.getClusterId() != null) {
|
||||
ClusterVO cluster = ApiDBUtils.findClusterById(host.getClusterId());
|
||||
hostResponse.setClusterName(cluster.getName());
|
||||
}
|
||||
|
||||
hostResponse.setLocalStorageActive(ApiDBUtils.isLocalStorageActiveOnHost(host));
|
||||
|
||||
Set<Event> possibleEvents = host.getStatus().getPossibleEvents();
|
||||
if ((possibleEvents != null) && !possibleEvents.isEmpty()) {
|
||||
String events = "";
|
||||
Iterator<Event> iter = possibleEvents.iterator();
|
||||
while (iter.hasNext()) {
|
||||
Event event = iter.next();
|
||||
events += event.toString();
|
||||
if (iter.hasNext()) {
|
||||
events += "; ";
|
||||
}
|
||||
}
|
||||
hostResponse.setEvents(events);
|
||||
}
|
||||
|
||||
hostResponse.setResponseName("host");
|
||||
return hostResponse;
|
||||
}
|
||||
}
|
||||
|
|
@ -43,22 +43,22 @@ public class ListStoragePoolsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="clusterid", type=CommandType.LONG)
|
||||
@Parameter(name="clusterid", type=CommandType.LONG, description="list storage pools belongig to the specific cluster")
|
||||
private Long clusterId;
|
||||
|
||||
@Parameter(name="ipaddress", type=CommandType.STRING)
|
||||
@Parameter(name="ipaddress", type=CommandType.STRING, description="the IP address for the storage pool")
|
||||
private String ipAddress;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the name of the storage pool")
|
||||
private String storagePoolName;
|
||||
|
||||
@Parameter(name="path", type=CommandType.STRING)
|
||||
@Parameter(name="path", type=CommandType.STRING, description="the storage pool path")
|
||||
private String path;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the Pod ID for the storage pool")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the Zone ID for the storage pool")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -44,25 +44,25 @@ public class ListSystemVMsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="hostid", type=CommandType.LONG)
|
||||
@Parameter(name="hostid", type=CommandType.LONG, description="the host ID of the system VM")
|
||||
private Long hostId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the ID of the system VM")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the name of the system VM")
|
||||
private String systemVmName;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the Pod ID of the system VM")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="state", type=CommandType.STRING)
|
||||
@Parameter(name="state", type=CommandType.STRING, description="the state of the system VM")
|
||||
private String state;
|
||||
|
||||
@Parameter(name="systemvmtype", type=CommandType.STRING)
|
||||
@Parameter(name="systemvmtype", type=CommandType.STRING, description="the system VM type. Possible types are \"consoleproxy\" and \"secondarystoragevm\".")
|
||||
private String systemVmType;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the Zone ID of the system VM")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -39,13 +39,13 @@ public class ListTemplateOrIsoPermissionsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="List template visibility and permissions for the specified account. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="List template visibility and permissions by domain. If used with the account parameter, specifies in which domain the specified account exists.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the template ID")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -51,25 +51,29 @@ public class ListTemplatesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="list template by account. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="list all templates in specified domain. If used with the account parameter, lists all templates for an account in the specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="hypervisor", type=CommandType.STRING)
|
||||
@Parameter(name="hypervisor", type=CommandType.STRING, description="the hypervisor for which to restrict the search")
|
||||
private String hypervisor;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the template ID")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the template name")
|
||||
private String templateName;
|
||||
|
||||
@Parameter(name="templatefilter", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="templatefilter", type=CommandType.STRING, required=true, description="possible values are \"featured\", \"self\", \"self-executable\", \"executable\", and \"community\"." +
|
||||
"* featured—templates that are featured and are public" +
|
||||
"* self—templates that have been registered/created by the owner" +
|
||||
"* selfexecutable— templates that have been registered/created by the owner that can be used to deploy a new VM" +
|
||||
"* executable— all templates that can be used to deploy a new VM* community—templates that are public.")
|
||||
private String templateFilter;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="list templates by zoneId")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,16 +41,16 @@ public class ListVMGroupsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="list instance groups by ID")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="list instance groups by name")
|
||||
private String groupName;
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="list instance group belonging to the specified account. Must be used with domainid parameter")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID. If used with the account parameter, lists virtual machines for the specified account in this domain.")
|
||||
private Long domainId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -48,28 +48,28 @@ public class ListVMsCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="account. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID. If used with the account parameter, lists virtual machines for the specified account in this domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="hostid", type=CommandType.LONG)
|
||||
@Parameter(name="hostid", type=CommandType.LONG, description="the host ID")
|
||||
private Long hostId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the ID of the virtual machine")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="name of the virtual machine")
|
||||
private String instanceName;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the pod ID")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="state", type=CommandType.STRING)
|
||||
@Parameter(name="state", type=CommandType.STRING, description="state of the virtual machine")
|
||||
private String state;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the availability zone ID")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -43,22 +43,22 @@ public class ListVlanIpRangesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account with which the VLAN IP range is associated. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="the domain ID with which the VLAN IP range is associated. If used with the account parameter, returns all VLAN IP ranges for that account in the specified domain.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the VLAN IP range")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
@Parameter(name="podid", type=CommandType.LONG, description="the Pod ID of the VLAN IP range")
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="vlan", type=CommandType.STRING)
|
||||
@Parameter(name="vlan", type=CommandType.STRING, description="the ID or VID of the VLAN. Default is an \"untagged\" VLAN.")
|
||||
private String vlan;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the Zone ID of the VLAN IP range")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -48,31 +48,31 @@ public class ListVolumesCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="account", type=CommandType.STRING)
|
||||
@Parameter(name="account", type=CommandType.STRING, description="the account associated with the disk volume. Must be used with the domainId parameter.")
|
||||
private String accountName;
|
||||
|
||||
@Parameter(name="domainid", type=CommandType.LONG)
|
||||
@Parameter(name="domainid", type=CommandType.LONG, description="Lists all disk volumes for the specified domain ID. If used with the account parameter, returns all disk volumes for an account in the specified domain ID.")
|
||||
private Long domainId;
|
||||
|
||||
@Parameter(name="hostid", type=CommandType.LONG)
|
||||
@Parameter(name="hostid", type=CommandType.LONG, description="list volumes on specified host")
|
||||
private Long hostId;
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG)
|
||||
@Parameter(name="id", type=CommandType.LONG, description="the ID of the disk volume")
|
||||
private Long id;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING)
|
||||
@Parameter(name="name", type=CommandType.STRING, description="the name of the disk volume")
|
||||
private String volumeName;
|
||||
|
||||
@Parameter(name="podid", type=CommandType.LONG)
|
||||
private Long podId;
|
||||
|
||||
@Parameter(name="type", type=CommandType.STRING)
|
||||
@Parameter(name="type", type=CommandType.STRING, description="the type of disk volume")
|
||||
private String type;
|
||||
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG)
|
||||
@Parameter(name="virtualmachineid", type=CommandType.LONG, description="the ID of the virtual machine")
|
||||
private Long virtualMachineId;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, description="the ID of the availability zone")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ public class ListZonesByCmd extends BaseListCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="available", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="available", type=CommandType.BOOLEAN, description="true if you want to retrieve all available Zones. False if you only want to return the Zones from which you have at least one VM. Default is false.")
|
||||
private Boolean available;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ public class PrepareForMaintenanceCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the host ID")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public class PreparePrimaryStorageForMaintenanceCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="Primary storage ID")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ public class QueryAsyncJobResultCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="jobid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="jobid", type=CommandType.LONG, required=true, description="the ID of the asychronous job")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ public class RebootRouterCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the ID of the router")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ public class RebootSystemVmCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="The ID of the system virtual machine")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ public class RebootVMCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="The ID of the virtual machine")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ public class ReconnectHostCmd extends BaseAsyncCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="the host ID")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ public class RecoverVMCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="id", type=CommandType.LONG, required=true, description="The ID of the virtual machine")
|
||||
private Long id;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -45,28 +45,28 @@ public class RegisterIsoCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
@Parameter(name="bootable", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="bootable", type=CommandType.BOOLEAN, description="true if this ISO is bootable")
|
||||
private Boolean bootable;
|
||||
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="displaytext", type=CommandType.STRING, required=true, description="the display text of the ISO. This is usually used for display purposes.")
|
||||
private String displayText;
|
||||
|
||||
@Parameter(name="isfeatured", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="isfeatured", type=CommandType.BOOLEAN, description="true if you want this ISO to be featured")
|
||||
private Boolean featured;
|
||||
|
||||
@Parameter(name="ispublic", type=CommandType.BOOLEAN)
|
||||
@Parameter(name="ispublic", type=CommandType.BOOLEAN, description="true if you want to register the ISO to be publicly available to all users, false otherwise.")
|
||||
private Boolean publicIso;
|
||||
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="name", type=CommandType.STRING, required=true, description="the name of the ISO")
|
||||
private String isoName;
|
||||
|
||||
@Parameter(name="ostypeid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="ostypeid", type=CommandType.LONG, required=true, description="the ID of the OS Type that best represents the OS of this ISO")
|
||||
private Long osTypeId;
|
||||
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="url", type=CommandType.STRING, required=true, description="the URL to where the ISO is currently being hosted")
|
||||
private String url;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description="the ID of the zone you wish to register the ISO to.")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -31,22 +31,26 @@ public class RegisterPreallocatedLunCmd extends BaseCmd {
|
|||
//////////////// API parameters /////////////////////
|
||||
/////////////////////////////////////////////////////
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="disksize", type=CommandType.LONG, required=true)
|
||||
private Long diskSize;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="lun", type=CommandType.INTEGER, required=true)
|
||||
private Integer lun;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="portal", type=CommandType.STRING, required=true)
|
||||
private String portal;
|
||||
|
||||
//FIXME - add description
|
||||
@Parameter(name="tags", type=CommandType.STRING)
|
||||
private String tags;
|
||||
|
||||
@Parameter(name="targetiqn", type=CommandType.STRING, required=true)
|
||||
@Parameter(name="targetiqn", type=CommandType.STRING, required=true, description="the target IQN on the storage host where LUN is created")
|
||||
private String targetIqn;
|
||||
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true)
|
||||
@Parameter(name="zoneid", type=CommandType.LONG, required=true, description="zone ID where LUN is going to be created")
|
||||
private Long zoneId;
|
||||
|
||||
/////////////////////////////////////////////////////
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue