cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From weiz...@apache.org
Subject git commit: updated refs/heads/master to f714d26
Date Mon, 03 Jun 2013 06:22:47 GMT
Updated Branches:
  refs/heads/master b4969c4af -> f714d2603


Revert "CLOUDSTACK-1301: Add VM Disk I/O Throttling"

This reverts commit 6dad8adf8fc22417f0242126b8f52ee081f74f49.


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

Branch: refs/heads/master
Commit: f714d2603914bbcce5dee307bf845a1e6b83e8f9
Parents: b4969c4
Author: Wei Zhou <w.zhou@leaseweb.com>
Authored: Mon Jun 3 07:48:03 2013 +0200
Committer: Wei Zhou <w.zhou@leaseweb.com>
Committed: Mon Jun 3 07:48:03 2013 +0200

----------------------------------------------------------------------
 api/src/com/cloud/agent/api/to/VolumeTO.java       |   18 ---
 api/src/com/cloud/offering/DiskOffering.java       |    8 --
 api/src/com/cloud/vm/DiskProfile.java              |   18 ---
 .../admin/offering/CreateDiskOfferingCmd.java      |   16 +---
 .../admin/offering/CreateServiceOfferingCmd.java   |   14 ---
 .../api/response/DiskOfferingResponse.java         |   14 ---
 .../api/response/ServiceOfferingResponse.java      |   14 ---
 .../cloudstack/api/response/VolumeResponse.java    |   14 ---
 .../WEB-INF/classes/resources/messages.properties  |    2 -
 .../com/cloud/agent/api/AttachVolumeCommand.java   |   18 ---
 .../src/com/cloud/storage/DiskOfferingVO.java      |   24 ----
 .../kvm/resource/LibvirtComputingResource.java     |   15 +---
 .../kvm/resource/LibvirtDomainXMLParser.java       |   15 ---
 .../hypervisor/kvm/resource/LibvirtVMDef.java      |   34 ------
 .../api/query/dao/DiskOfferingJoinDaoImpl.java     |    2 -
 .../api/query/dao/ServiceOfferingJoinDaoImpl.java  |    2 -
 .../com/cloud/api/query/dao/VolumeJoinDaoImpl.java |    2 -
 .../com/cloud/api/query/vo/DiskOfferingJoinVO.java |   21 ----
 .../cloud/api/query/vo/ServiceOfferingJoinVO.java  |   20 ----
 .../src/com/cloud/api/query/vo/VolumeJoinVO.java   |   22 ----
 server/src/com/cloud/configuration/Config.java     |    2 -
 .../cloud/configuration/ConfigurationManager.java  |    4 +-
 .../configuration/ConfigurationManagerImpl.java    |   20 +---
 server/src/com/cloud/storage/StorageManager.java   |    6 -
 .../src/com/cloud/storage/StorageManagerImpl.java  |   34 ------
 .../src/com/cloud/storage/VolumeManagerImpl.java   |   24 +----
 server/src/com/cloud/test/DatabaseConfig.java      |    6 -
 .../com/cloud/vm/VirtualMachineManagerImpl.java    |    2 +-
 .../cloud/vpc/MockConfigurationManagerImpl.java    |    4 +-
 setup/db/db/schema-410to420.sql                    |   15 +---
 ui/dictionary.jsp                                  |    2 -
 ui/scripts/configuration.js                        |   82 ---------------
 ui/scripts/instances.js                            |    4 +-
 33 files changed, 17 insertions(+), 481 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/com/cloud/agent/api/to/VolumeTO.java
----------------------------------------------------------------------
diff --git a/api/src/com/cloud/agent/api/to/VolumeTO.java b/api/src/com/cloud/agent/api/to/VolumeTO.java
index 8b3a6be..4cbe82b 100644
--- a/api/src/com/cloud/agent/api/to/VolumeTO.java
+++ b/api/src/com/cloud/agent/api/to/VolumeTO.java
@@ -37,8 +37,6 @@ public class VolumeTO implements InternalIdentity {
     private long deviceId;
     private String chainInfo;
     private String guestOsType;
-    private long bytesRate;
-    private long iopsRate;
 
     public VolumeTO(long id, Volume.Type type, StoragePoolType poolType, String poolUuid, String name, String mountPoint, String path, long size, String chainInfo) {
         this.id = id;
@@ -135,20 +133,4 @@ public class VolumeTO implements InternalIdentity {
     public String toString() {
         return new StringBuilder("Vol[").append(id).append("|").append(type).append("|").append(path).append("|").append(size).append("]").toString();
     }
-    
-    public void setBytesRate(long bytesRate) {
-        this.bytesRate = bytesRate;
-    }
-    
-    public long getBytesRate() {
-        return bytesRate;
-    }
-    
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-    
-    public long getIopsRate() {
-        return iopsRate;
-    }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/com/cloud/offering/DiskOffering.java
----------------------------------------------------------------------
diff --git a/api/src/com/cloud/offering/DiskOffering.java b/api/src/com/cloud/offering/DiskOffering.java
index 1618db9..dd77c70 100644
--- a/api/src/com/cloud/offering/DiskOffering.java
+++ b/api/src/com/cloud/offering/DiskOffering.java
@@ -52,12 +52,4 @@ public interface DiskOffering extends InfrastructureEntity, Identity, InternalId
     boolean isCustomized();
 
     void setDiskSize(long diskSize);
-    
-    void setBytesRate(long bytesRate);
-    
-    long getBytesRate();
-    
-    void setIopsRate(long iopsRate);
-    
-    long getIopsRate();
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/com/cloud/vm/DiskProfile.java
----------------------------------------------------------------------
diff --git a/api/src/com/cloud/vm/DiskProfile.java b/api/src/com/cloud/vm/DiskProfile.java
index 2c77006..e3a3386 100644
--- a/api/src/com/cloud/vm/DiskProfile.java
+++ b/api/src/com/cloud/vm/DiskProfile.java
@@ -35,8 +35,6 @@ public class DiskProfile {
     private Long templateId;
     private long volumeId;
     private String path;
-    private long bytesRate;
-    private long iopsRate;
 
     private HypervisorType hyperType;
 
@@ -156,20 +154,4 @@ public class DiskProfile {
     public void setSize(long size) {
     	this.size = size;
     }
-    
-    public void setBytesRate(long bytesRate) {
-        this.bytesRate = bytesRate;
-    }
-    
-    public long getBytesRate() {
-        return bytesRate;
-    }
-    
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-    
-    public long getIopsRate() {
-        return iopsRate;
-    }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/org/apache/cloudstack/api/command/admin/offering/CreateDiskOfferingCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/admin/offering/CreateDiskOfferingCmd.java b/api/src/org/apache/cloudstack/api/command/admin/offering/CreateDiskOfferingCmd.java
index 848d158..aa11599 100644
--- a/api/src/org/apache/cloudstack/api/command/admin/offering/CreateDiskOfferingCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/admin/offering/CreateDiskOfferingCmd.java
@@ -61,12 +61,6 @@ public class CreateDiskOfferingCmd extends BaseCmd {
 
     @Parameter(name=ApiConstants.STORAGE_TYPE, type=CommandType.STRING, description="the storage type of the disk offering. Values are local and shared.")
     private String storageType = ServiceOffering.StorageType.shared.toString();
-    
-    @Parameter(name="bytesRate", type=CommandType.LONG, required=false, description="bytes rate of the disk offering")
-    private Long bytesRate;
-
-    @Parameter(name="iopsRate", type=CommandType.LONG, required=false, description="io requests rate of the disk offering")
-    private Long iopsRate;
 
     @Parameter(name=ApiConstants.DISPLAY_OFFERING, type=CommandType.BOOLEAN, description="an optional field, whether to display the offering to the end user or not.")
     private Boolean displayOffering;
@@ -98,14 +92,6 @@ public class CreateDiskOfferingCmd extends BaseCmd {
     public Long getDomainId(){
         return domainId;
     }
-    
-    public Long getBytesRate() {
-        return bytesRate;
-    }
-    
-    public Long getIopsRate() {
-        return iopsRate;
-    }
 
     public String getStorageType() {
         return storageType;
@@ -128,7 +114,7 @@ public class CreateDiskOfferingCmd extends BaseCmd {
     public long getEntityOwnerId() {
         return Account.ACCOUNT_ID_SYSTEM;
     }
-    
+
     @Override
     public void execute(){
         DiskOffering offering = _configService.createDiskOffering(this);

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java b/api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java
index 28f1a68..4c54a4e 100644
--- a/api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/admin/offering/CreateServiceOfferingCmd.java
@@ -93,12 +93,6 @@ public class CreateServiceOfferingCmd extends BaseCmd {
     @Parameter(name = ApiConstants.SERVICE_OFFERING_DETAILS, type = CommandType.MAP, description = "details for planner, used to store specific parameters")
     private Map<String, String> details;
 
-    @Parameter(name="bytesRate", type=CommandType.LONG, required=false, description="bytes rate of the disk offering")
-    private Long bytesRate;
-
-    @Parameter(name="iopsRate", type=CommandType.LONG, required=false, description="io requests rate of the disk offering")
-    private Long iopsRate;
-
     /////////////////////////////////////////////////////
     /////////////////// Accessors ///////////////////////
     /////////////////////////////////////////////////////
@@ -177,14 +171,6 @@ public class CreateServiceOfferingCmd extends BaseCmd {
         return params;
     }
 
-    public long getBytesRate() {
-       return bytesRate;
-    }
-
-    public long getIopsRate() {
-        return iopsRate;
-    }
-
     /////////////////////////////////////////////////////
     /////////////// API Implementation///////////////////
     /////////////////////////////////////////////////////

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/org/apache/cloudstack/api/response/DiskOfferingResponse.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/response/DiskOfferingResponse.java b/api/src/org/apache/cloudstack/api/response/DiskOfferingResponse.java
index 8d4bec3..377e66e 100644
--- a/api/src/org/apache/cloudstack/api/response/DiskOfferingResponse.java
+++ b/api/src/org/apache/cloudstack/api/response/DiskOfferingResponse.java
@@ -57,12 +57,6 @@ public class DiskOfferingResponse extends BaseResponse {
 
     @SerializedName("storagetype") @Param(description="the storage type for this disk offering")
     private String storageType;
-    
-    @SerializedName("diskBytesRate") @Param(description="bytes rate of the disk offering")
-    private Long bytesRate;
-
-    @SerializedName("diskIORate") @Param(description="io requests rate of the disk offering")
-    private Long iopsRate;
 
     @SerializedName("displayoffering") @Param(description="whether to display the offering to the end user or not.")
     private Boolean displayOffering;
@@ -155,12 +149,4 @@ public class DiskOfferingResponse extends BaseResponse {
     public void setStorageType(String storageType) {
         this.storageType = storageType;
     }
-    
-    public void setBytesRate(long bytesRate) {
-        this.bytesRate = bytesRate;
-    }
-    
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java b/api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java
index b98fd4d..31533f8 100644
--- a/api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java
+++ b/api/src/org/apache/cloudstack/api/response/ServiceOfferingResponse.java
@@ -86,12 +86,6 @@ public class ServiceOfferingResponse extends BaseResponse {
 
     @SerializedName(ApiConstants.NETWORKRATE) @Param(description="data transfer rate in megabits per second allowed.")
     private Integer networkRate;
-    
-    @SerializedName("diskBytesRate") @Param(description="bytes rate of the service offering")
-    private Long bytesRate;
-
-    @SerializedName("diskIORate") @Param(description="io requests rate of the service offering")
-    private Long iopsRate;
 
     @SerializedName(ApiConstants.DEPLOYMENT_PLANNER) @Param(description="deployment strategy used to deploy VM.")
     private String deploymentPlanner;
@@ -254,12 +248,4 @@ public class ServiceOfferingResponse extends BaseResponse {
     public void setVolatileVm(boolean isVolatile) {
         this.isVolatile = isVolatile;
     }
-    
-    public void setBytesRate(long bytesRate) {
-        this.bytesRate = bytesRate;
-    }
-    
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/api/src/org/apache/cloudstack/api/response/VolumeResponse.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/response/VolumeResponse.java b/api/src/org/apache/cloudstack/api/response/VolumeResponse.java
index 8e38d85..21d7d1a 100644
--- a/api/src/org/apache/cloudstack/api/response/VolumeResponse.java
+++ b/api/src/org/apache/cloudstack/api/response/VolumeResponse.java
@@ -110,12 +110,6 @@ public class VolumeResponse extends BaseResponse implements ControlledViewEntity
     @Param(description = "shared or local storage")
     private String storageType;
 
-    @SerializedName("diskBytesRate") @Param(description="bytes rate of the disk offering")
-    private Long bytesRate;
-
-    @SerializedName("diskIORate") @Param(description="io requests rate of the disk offering")
-    private Long iopsRate;
-
     @SerializedName(ApiConstants.HYPERVISOR)
     @Param(description = "Hypervisor the volume belongs to")
     private String hypervisor;
@@ -264,14 +258,6 @@ public class VolumeResponse extends BaseResponse implements ControlledViewEntity
         this.storageType = storageType;
     }
 
-    public void setBytesRate(long bytesRate) {
-        this.bytesRate = bytesRate;
-    }
-
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-
     public void setHypervisor(String hypervisor) {
         this.hypervisor = hypervisor;
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/client/WEB-INF/classes/resources/messages.properties
----------------------------------------------------------------------
diff --git a/client/WEB-INF/classes/resources/messages.properties b/client/WEB-INF/classes/resources/messages.properties
index fc7715d..ce20fa4 100644
--- a/client/WEB-INF/classes/resources/messages.properties
+++ b/client/WEB-INF/classes/resources/messages.properties
@@ -463,8 +463,6 @@ label.disable.vpn=Disable VPN
 label.disabled=Disabled
 label.disabling.vpn.access=Disabling VPN Access
 label.disk.allocated=Disk Allocated
-label.disk.bytes.rate=Disk Rate (BPS)
-label.disk.iops.rate=Disk Rate (IOPS)
 label.disk.offering=Disk Offering
 label.disk.read.bytes=Disk Read (Bytes)
 label.disk.read.io=Disk Read (IO)

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/core/src/com/cloud/agent/api/AttachVolumeCommand.java
----------------------------------------------------------------------
diff --git a/core/src/com/cloud/agent/api/AttachVolumeCommand.java b/core/src/com/cloud/agent/api/AttachVolumeCommand.java
index 101c254..302b8f8 100644
--- a/core/src/com/cloud/agent/api/AttachVolumeCommand.java
+++ b/core/src/com/cloud/agent/api/AttachVolumeCommand.java
@@ -29,8 +29,6 @@ public class AttachVolumeCommand extends Command {
 	String volumeName;
 	Long deviceId;
 	String chainInfo;
-    long bytesRate;
-    long iopsRate;
 
 	protected AttachVolumeCommand() {
 	}
@@ -98,20 +96,4 @@ public class AttachVolumeCommand extends Command {
     public String getChainInfo() {
     	return chainInfo;
     }
-    
-    public void setBytesRate(long bytesRate) {
-        this.bytesRate = bytesRate;
-    }
-    
-    public long getBytesRate() {
-        return bytesRate;
-    }
-    
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-    
-    public long getIopsRate() {
-        return iopsRate;
-    }
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/storage/DiskOfferingVO.java b/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
index 239ddb0..909d7fe 100755
--- a/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
+++ b/engine/schema/src/com/cloud/storage/DiskOfferingVO.java
@@ -99,13 +99,6 @@ public class DiskOfferingVO implements DiskOffering {
 
     @Column(name="sort_key")
     int sortKey;
-    
-    @Column(name="bytes_rate")
-    long bytesRate;
-
-    @Column(name="iops_rate")
-    long iopsRate;
-
 
     @Column(name="display_offering")
     boolean displayOffering;
@@ -334,21 +327,4 @@ public class DiskOfferingVO implements DiskOffering {
     public void setDisplayOffering(boolean displayOffering) {
         this.displayOffering = displayOffering;
     }
-
-    public void setBytesRate(long bytesRate) {
-       this.bytesRate = bytesRate;
-    }
-
-    public long getBytesRate() {
-       return bytesRate;
-    }
-
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-
-    public long getIopsRate() {
-        return iopsRate;
-    }
-
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java
----------------------------------------------------------------------
diff --git a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java
index 9b26ef2..46fce24 100755
--- a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java
+++ b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java
@@ -1393,8 +1393,6 @@ ServerResource {
             VolumeTO volume = new VolumeTO(cmd.getVolumeId(), dskch.getType(),
                     pool.getType(), pool.getUuid(), pool.getPath(),
                     vol.getName(), vol.getName(), disksize, null);
-            volume.setBytesRate(dskch.getBytesRate());
-            volume.setIopsRate(dskch.getIopsRate());
             return new CreateAnswer(cmd, volume);
         } catch (CloudRuntimeException e) {
             s_logger.debug("Failed to create volume: " + e.toString());
@@ -2610,7 +2608,7 @@ ServerResource {
                     cmd.getPoolUuid());
             KVMPhysicalDisk disk = primary.getPhysicalDisk(cmd.getVolumePath());
             attachOrDetachDisk(conn, cmd.getAttach(), cmd.getVmName(), disk,
-                    cmd.getDeviceId().intValue(), cmd.getBytesRate(), cmd.getIopsRate());
+                    cmd.getDeviceId().intValue());
         } catch (LibvirtException e) {
             return new AttachVolumeAnswer(cmd, e.toString());
         } catch (InternalErrorException e) {
@@ -3478,11 +3476,6 @@ ServerResource {
                 }
 
             }
-            
-            if (volume.getBytesRate() > 0)
-                disk.setBytesRate(volume.getBytesRate());
-            if (volume.getIopsRate() > 0)
-                disk.setIopsRate(volume.getIopsRate());
 
             vm.getDevices().addDevice(disk);
         }
@@ -3617,7 +3610,7 @@ ServerResource {
 
     protected synchronized String attachOrDetachDisk(Connect conn,
             boolean attach, String vmName, KVMPhysicalDisk attachingDisk,
-            int devId, long bytesRate, long iopsRate) throws LibvirtException, InternalErrorException {
+            int devId) throws LibvirtException, InternalErrorException {
         List<DiskDef> disks = null;
         Domain dm = null;
         DiskDef diskdef = null;
@@ -3657,10 +3650,6 @@ ServerResource {
                     diskdef.defBlockBasedDisk(attachingDisk.getPath(), devId,
                             DiskDef.diskBus.VIRTIO);
                 }
-                if (bytesRate > 0)
-                    diskdef.setBytesRate(bytesRate);
-                if (iopsRate > 0)
-                    diskdef.setIopsRate(iopsRate);
             }
 
             String xml = diskdef.toString();

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java
----------------------------------------------------------------------
diff --git a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java
index cccdc39..b8645e1 100644
--- a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java
+++ b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java
@@ -105,21 +105,6 @@ public class LibvirtDomainXMLParser {
                                 DiskDef.diskBus.valueOf(bus.toUpperCase()));
                     }
                 }
-                
-                NodeList iotune = disk.getElementsByTagName("iotune");
-                if ((iotune != null) && (iotune.getLength() !=0)) {
-                    String bytesRateStr = getTagValue("total_bytes_sec", (Element)iotune.item(0));
-                    if (bytesRateStr != null) {
-                        Long bytesRate = Long.parseLong(bytesRateStr);
-                        def.setBytesRate(bytesRate);
-                    }
-                    String iopsRateStr = getTagValue("total_iops_sec", (Element)iotune.item(0));
-                    if (iopsRateStr != null) {
-                        Long iopsRate = Long.parseLong(iopsRateStr);
-                        def.setIopsRate(iopsRate);
-                    }
-                }
-
                 diskDefs.add(def);
             }
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java
----------------------------------------------------------------------
diff --git a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java
index 2959821..9cddb2e 100644
--- a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java
+++ b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java
@@ -22,8 +22,6 @@ import java.util.List;
 import java.util.Map;
 import java.util.UUID;
 
-import com.cloud.utils.script.Script;
-
 public class LibvirtVMDef {
     private String _hvsType;
     private String _domName;
@@ -441,8 +439,6 @@ public class LibvirtVMDef {
         private boolean _readonly = false;
         private boolean _shareable = false;
         private boolean _deferAttach = false;
-        private Long _bytesRate;
-        private Long _iopsRate;
 
         public void setDeviceType(deviceType deviceType) {
             _deviceType = deviceType;
@@ -587,14 +583,6 @@ public class LibvirtVMDef {
             char suffix = this._diskLabel.charAt(this._diskLabel.length() - 1);
             return suffix - 'a';
         }
-        
-        public void setBytesRate(Long bytesRate) {
-            _bytesRate = bytesRate;
-        }
-        
-        public void setIopsRate(Long iopsRate) {
-            _iopsRate = iopsRate;
-        }
 
         @Override
         public String toString() {
@@ -639,28 +627,6 @@ public class LibvirtVMDef {
                 diskBuilder.append(" bus='" + _bus + "'");
             }
             diskBuilder.append("/>\n");
-            
-            String libvirtVersion = Script.runSimpleBashScript("virsh version |grep API | awk '{print $4}'");
-            String qemuVersion = Script.runSimpleBashScript("virsh version |grep hypervisor | awk '{print $4}'");
-            if ((_deviceType != deviceType.CDROM) && (libvirtVersion != null) && (qemuVersion != null) 
-                    && (((_bytesRate != null) && (_bytesRate > 0)) || ((_iopsRate != null) && (_iopsRate > 0)))) { // not CDROM, from libvirt 0.9.8 and QEMU 1.1.0
-                String[] libvirtVersions = libvirtVersion.split("\\.");
-                String[] qemuVersions = qemuVersion.split("\\.");
-                if (((libvirtVersions != null) && (libvirtVersions.length == 3) && ((Integer.valueOf(libvirtVersions[0]) > 0)
-                        || ((Integer.valueOf(libvirtVersions[0]) == 0) && (Integer.valueOf(libvirtVersions[1]) > 9))
-                        || ((Integer.valueOf(libvirtVersions[0]) == 0) && (Integer.valueOf(libvirtVersions[1]) == 9) && (Integer.valueOf(libvirtVersions[1]) >= 8))))
-                        && ((qemuVersions != null) && (qemuVersions.length == 3) && ((Integer.valueOf(qemuVersions[0]) > 1)
-                        || ((Integer.valueOf(qemuVersions[0]) == 1) && (Integer.valueOf(qemuVersions[1]) > 1))
-                        || ((Integer.valueOf(qemuVersions[0]) == 1) && (Integer.valueOf(qemuVersions[1]) == 1) && (Integer.valueOf(qemuVersions[1]) >= 0))))) {
-                    diskBuilder.append("<iotune>\n");
-                    if ((_bytesRate != null) && (_bytesRate > 0))
-                        diskBuilder.append("<total_bytes_sec>" + _bytesRate + "</total_bytes_sec>\n");
-                    if ((_iopsRate != null) && (_iopsRate > 0))
-                        diskBuilder.append("<total_iops_sec>" + _iopsRate + "</total_iops_sec>\n");
-                    diskBuilder.append("</iotune>\n");
-                }
-            }
-            
             diskBuilder.append("</disk>\n");
             return diskBuilder.toString();
         }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/api/query/dao/DiskOfferingJoinDaoImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/dao/DiskOfferingJoinDaoImpl.java b/server/src/com/cloud/api/query/dao/DiskOfferingJoinDaoImpl.java
index bfae58b..283181f 100644
--- a/server/src/com/cloud/api/query/dao/DiskOfferingJoinDaoImpl.java
+++ b/server/src/com/cloud/api/query/dao/DiskOfferingJoinDaoImpl.java
@@ -76,8 +76,6 @@ public class DiskOfferingJoinDaoImpl extends GenericDaoBase<DiskOfferingJoinVO,
         diskOfferingResponse.setCustomized(offering.isCustomized());
         diskOfferingResponse.setStorageType(offering.isUseLocalStorage() ? ServiceOffering.StorageType.local.toString() : ServiceOffering.StorageType.shared.toString());
         diskOfferingResponse.setObjectName("diskoffering");
-        diskOfferingResponse.setBytesRate(offering.getBytesRate());
-        diskOfferingResponse.setIopsRate(offering.getIopsRate());
         return diskOfferingResponse;
     }
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java b/server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java
index ec67175..56e4d0a 100644
--- a/server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java
+++ b/server/src/com/cloud/api/query/dao/ServiceOfferingJoinDaoImpl.java
@@ -76,8 +76,6 @@ public class ServiceOfferingJoinDaoImpl extends GenericDaoBase<ServiceOfferingJo
         offeringResponse.setHostTag(offering.getHostTag());
         offeringResponse.setDeploymentPlanner(offering.getDeploymentPlanner());
         offeringResponse.setObjectName("serviceoffering");
-        offeringResponse.setBytesRate(offering.getBytesRate());
-        offeringResponse.setIopsRate(offering.getIopsRate());
 
         return offeringResponse;
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/api/query/dao/VolumeJoinDaoImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/dao/VolumeJoinDaoImpl.java b/server/src/com/cloud/api/query/dao/VolumeJoinDaoImpl.java
index e65f78a..e27e2d9 100644
--- a/server/src/com/cloud/api/query/dao/VolumeJoinDaoImpl.java
+++ b/server/src/com/cloud/api/query/dao/VolumeJoinDaoImpl.java
@@ -160,8 +160,6 @@ public class VolumeJoinDaoImpl extends GenericDaoBase<VolumeJoinVO, Long> implem
             }
             volResponse.setStorageType(volume.isUseLocalStorage() ? ServiceOffering.StorageType.local.toString() : ServiceOffering.StorageType.shared
                     .toString());
-            volResponse.setBytesRate(volume.getBytesRate());
-            volResponse.setIopsRate(volume.getIopsRate());
         }
         Long poolId = volume.getPoolId();
         String poolName = (poolId == null) ? "none" : volume.getPoolName();

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/api/query/vo/DiskOfferingJoinVO.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/vo/DiskOfferingJoinVO.java b/server/src/com/cloud/api/query/vo/DiskOfferingJoinVO.java
index c44c171..6d3cdcb 100644
--- a/server/src/com/cloud/api/query/vo/DiskOfferingJoinVO.java
+++ b/server/src/com/cloud/api/query/vo/DiskOfferingJoinVO.java
@@ -64,12 +64,6 @@ public class DiskOfferingJoinVO extends BaseViewVO implements InternalIdentity,
     @Column(name="sort_key")
     int sortKey;
 
-    @Column(name="bytes_rate")
-    long bytesRate;
-
-    @Column(name="iops_rate")
-    long iopsRate;
-
     @Column(name="type")
     Type type;
 
@@ -245,21 +239,6 @@ public class DiskOfferingJoinVO extends BaseViewVO implements InternalIdentity,
         this.type = type;
     }
 
-    public void setBytesRate(long bytesRate) {
-       this.bytesRate = bytesRate;
-    }
-
-    public long getBytesRate() {
-       return bytesRate;
-    }
-
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-
-    public long getIopsRate() {
-        return iopsRate;
-    }
 
 
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java b/server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java
index 89c665e..e87a101 100644
--- a/server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java
+++ b/server/src/com/cloud/api/query/vo/ServiceOfferingJoinVO.java
@@ -90,11 +90,6 @@ public class ServiceOfferingJoinVO extends BaseViewVO implements InternalIdentit
     @Column(name="sort_key")
     int sortKey;
 
-    @Column(name="bytes_rate")
-    long bytesRate;
-
-    @Column(name="iops_rate")
-    long iopsRate;
 
     @Column(name=GenericDao.CREATED_COLUMN)
     private Date created;
@@ -334,20 +329,5 @@ public class ServiceOfferingJoinVO extends BaseViewVO implements InternalIdentit
         this.volatileVm = volatileVm;
     }
 
-    public void setBytesRate(long bytesRate) {
-        this.bytesRate = bytesRate;
-    }
-
-    public long getBytesRate() {
-        return bytesRate;
-    }
-
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-
-    public long getIopsRate() {
-        return iopsRate;
-    }
 
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/api/query/vo/VolumeJoinVO.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/vo/VolumeJoinVO.java b/server/src/com/cloud/api/query/vo/VolumeJoinVO.java
index 5831659..6ef8c91 100644
--- a/server/src/com/cloud/api/query/vo/VolumeJoinVO.java
+++ b/server/src/com/cloud/api/query/vo/VolumeJoinVO.java
@@ -184,12 +184,6 @@ public class VolumeJoinVO extends BaseViewVO implements ControlledViewEntity {
     @Column(name="use_local_storage")
     private boolean useLocalStorage;
 
-    @Column(name="bytes_rate")
-    long bytesRate;
-
-    @Column(name="iops_rate")
-    long iopsRate;
-
     @Column(name="pool_id")
     private long poolId;
 
@@ -748,22 +742,6 @@ public class VolumeJoinVO extends BaseViewVO implements ControlledViewEntity {
     }
 
 
-    public void setBytesRate(long bytesRate) {
-       this.bytesRate = bytesRate;
-    }
-
-    public long getBytesRate() {
-       return bytesRate;
-    }
-
-    public void setIopsRate(long iopsRate) {
-        this.iopsRate = iopsRate;
-    }
-
-    public long getIopsRate() {
-        return iopsRate;
-    }
-
 
     public long getPoolId() {
         return poolId;

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/configuration/Config.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/configuration/Config.java b/server/src/com/cloud/configuration/Config.java
index d822ae2..5ee0fad 100755
--- a/server/src/com/cloud/configuration/Config.java
+++ b/server/src/com/cloud/configuration/Config.java
@@ -232,8 +232,6 @@ public enum Config {
 	VmDiskStatsInterval("Advanced", ManagementServer.class, Integer.class, "vm.disk.stats.interval", "0", "Interval (in seconds) to report vm disk statistics.", null),
 	VmTransitionWaitInterval("Advanced", ManagementServer.class, Integer.class, "vm.tranisition.wait.interval", "3600", "Time (in seconds) to wait before taking over a VM in transition state", null),
 	VmDestroyForcestop("Advanced", ManagementServer.class, Boolean.class, "vm.destroy.forcestop", "false", "On destroy, force-stop takes this value ", null),
-        VmDiskThrottlingIORate("Advanced", ManagementServer.class, Integer.class, "vm.disk.throttling.iops_rate", "0", "Default disk I/O rate in requests per second allowed in User vm's disk.", null),
-        VmDiskThrottlingBytesRate("Advanced", ManagementServer.class, Integer.class, "vm.disk.throttling.bytes_rate", "0", "Default disk I/O rate in bytes per second allowed in User vm's disk.", null),
 
 	ControlCidr("Advanced", ManagementServer.class, String.class, "control.cidr", "169.254.0.0/16", "Changes the cidr for the control network traffic.  Defaults to using link local.  Must be unique within pods", null),
 	ControlGateway("Advanced", ManagementServer.class, String.class, "control.gateway", "169.254.0.1", "gateway for the control network traffic", null),

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/configuration/ConfigurationManager.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/configuration/ConfigurationManager.java b/server/src/com/cloud/configuration/ConfigurationManager.java
index 975fad1..8db037b 100755
--- a/server/src/com/cloud/configuration/ConfigurationManager.java
+++ b/server/src/com/cloud/configuration/ConfigurationManager.java
@@ -84,7 +84,7 @@ public interface ConfigurationManager extends ConfigurationService, Manager {
      * @return ID
      */
     ServiceOfferingVO createServiceOffering(long userId, boolean isSystem, VirtualMachine.Type vm_typeType, String name, int cpu, int ramSize, int speed, String displayText, boolean localStorageRequired,
-            boolean offerHA, boolean limitResourceUse, boolean volatileVm, String tags, Long domainId, String hostTag, Integer networkRate, String deploymentPlanner, Map<String, String> details, Long bytesRate, Long iopsRate);
+            boolean offerHA, boolean limitResourceUse, boolean volatileVm, String tags, Long domainId, String hostTag, Integer networkRate, String deploymentPlanner, Map<String, String> details);
 
     /**
      * Creates a new disk offering
@@ -99,7 +99,7 @@ public interface ConfigurationManager extends ConfigurationService, Manager {
      * @param isDisplayOfferingEnabled
      * @return newly created disk offering
      */
-    DiskOfferingVO createDiskOffering(Long domainId, String name, String description, Long numGibibytes, String tags, boolean isCustomized, boolean localStorageRequired, boolean isDisplayOfferingEnabled, Long bytesRate, Long iopsRate);
+    DiskOfferingVO createDiskOffering(Long domainId, String name, String description, Long numGibibytes, String tags, boolean isCustomized, boolean localStorageRequired, boolean isDisplayOfferingEnabled);
 
     /**
      * Creates a new pod

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
index 0bfd286..59e70cf 100755
--- a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
+++ b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
@@ -2031,8 +2031,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati
         return createServiceOffering(userId, cmd.getIsSystem(), vmType, cmd.getServiceOfferingName(),
                 cpuNumber.intValue(), memory.intValue(), cpuSpeed.intValue(), cmd.getDisplayText(),
                 localStorageRequired, offerHA, limitCpuUse, volatileVm, cmd.getTags(), cmd.getDomainId(),
-                cmd.getHostTag(), cmd.getNetworkRate(), cmd.getDeploymentPlanner(), cmd.getDetails(),
-                cmd.getBytesRate(), cmd.getIopsRate());
+                cmd.getHostTag(), cmd.getNetworkRate(), cmd.getDeploymentPlanner(), cmd.getDetails());
     }
 
     @Override
@@ -2040,16 +2039,11 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati
     public ServiceOfferingVO createServiceOffering(long userId, boolean isSystem, VirtualMachine.Type vm_type,
             String name, int cpu, int ramSize, int speed, String displayText, boolean localStorageRequired,
             boolean offerHA, boolean limitResourceUse, boolean volatileVm,  String tags, Long domainId, String hostTag,
-            Integer networkRate, String deploymentPlanner, Map<String, String> details, Long bytesRate, Long iopsRate) {
+            Integer networkRate, String deploymentPlanner, Map<String, String> details) {
         tags = cleanupTags(tags);
         ServiceOfferingVO offering = new ServiceOfferingVO(name, cpu, ramSize, speed, networkRate, null, offerHA, limitResourceUse, volatileVm, displayText, localStorageRequired, false, tags, isSystem, vm_type,
                 domainId, hostTag, deploymentPlanner);
 
-        if ((bytesRate != null) && (bytesRate > 0))
-            offering.setBytesRate(bytesRate);
-        if ((iopsRate != null) && (iopsRate > 0))
-            offering.setIopsRate(iopsRate);
-
         if ((offering = _serviceOfferingDao.persist(offering)) != null) {
             if (details != null) {
                 _serviceOfferingDetailsDao.persist(offering.getId(), details);
@@ -2135,7 +2129,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati
 
     @Override
     @ActionEvent(eventType = EventTypes.EVENT_DISK_OFFERING_CREATE, eventDescription = "creating disk offering")
-    public DiskOfferingVO createDiskOffering(Long domainId, String name, String description, Long numGibibytes, String tags, boolean isCustomized, boolean localStorageRequired, boolean isDisplayOfferingEnabled, Long bytesRate, Long iopsRate) {
+    public DiskOfferingVO createDiskOffering(Long domainId, String name, String description, Long numGibibytes, String tags, boolean isCustomized, boolean localStorageRequired, boolean isDisplayOfferingEnabled) {
         long diskSize = 0;// special case for custom disk offerings
         if (numGibibytes != null && (numGibibytes <= 0)) {
             throw new InvalidParameterValueException("Please specify a disk size of at least 1 Gb.");
@@ -2155,10 +2149,6 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati
         DiskOfferingVO newDiskOffering = new DiskOfferingVO(domainId, name, description, diskSize, tags, isCustomized);
         newDiskOffering.setUseLocalStorage(localStorageRequired);
         newDiskOffering.setDisplayOffering(isDisplayOfferingEnabled);
-        if (bytesRate != null && (bytesRate > 0))
-            newDiskOffering.setBytesRate(bytesRate);
-        if (iopsRate != null && (iopsRate > 0))
-            newDiskOffering.setIopsRate(iopsRate);
         UserContext.current().setEventDetails("Disk offering id=" + newDiskOffering.getId());
         DiskOfferingVO offering = _diskOfferingDao.persist(newDiskOffering);
         if (offering != null) {
@@ -2199,9 +2189,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati
             }
         }
 
-        Long bytesRate = cmd.getBytesRate();
-        Long iopsRate = cmd.getIopsRate();
-        return createDiskOffering(domainId, name, description, numGibibytes, tags, isCustomized, localStorageRequired, isDisplayOfferingEnabled, bytesRate, iopsRate);
+        return createDiskOffering(domainId, name, description, numGibibytes, tags, isCustomized, localStorageRequired, isDisplayOfferingEnabled);
     }
 
     @Override

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/storage/StorageManager.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/storage/StorageManager.java b/server/src/com/cloud/storage/StorageManager.java
index 7f5b3ff..d49a7f8 100755
--- a/server/src/com/cloud/storage/StorageManager.java
+++ b/server/src/com/cloud/storage/StorageManager.java
@@ -35,8 +35,6 @@ import com.cloud.exception.ConnectionException;
 import com.cloud.exception.StorageUnavailableException;
 import com.cloud.host.Host;
 import com.cloud.hypervisor.Hypervisor.HypervisorType;
-import com.cloud.service.ServiceOfferingVO;
-import com.cloud.storage.DiskOfferingVO;
 import com.cloud.storage.Storage.ImageFormat;
 import com.cloud.utils.Pair;
 import com.cloud.vm.DiskProfile;
@@ -124,8 +122,4 @@ public interface StorageManager extends StorageService {
     DataStore createLocalStorage(Host host, StoragePoolInfo poolInfo) throws ConnectionException;
 
     BigDecimal getStorageOverProvisioningFactor(Long dcId);
-
-    Long getDiskBytesRate(ServiceOfferingVO offering, DiskOfferingVO diskOffering);
-
-    Long getDiskIORate(ServiceOfferingVO offering, DiskOfferingVO diskOffering);
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/storage/StorageManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/storage/StorageManagerImpl.java b/server/src/com/cloud/storage/StorageManagerImpl.java
index cdfc19a..d38b35e 100755
--- a/server/src/com/cloud/storage/StorageManagerImpl.java
+++ b/server/src/com/cloud/storage/StorageManagerImpl.java
@@ -127,7 +127,6 @@ import com.cloud.resource.ResourceState;
 import com.cloud.server.ManagementServer;
 import com.cloud.server.StatsCollector;
 import com.cloud.service.dao.ServiceOfferingDao;
-import com.cloud.service.ServiceOfferingVO;
 import com.cloud.storage.Storage.ImageFormat;
 import com.cloud.storage.Storage.StoragePoolType;
 import com.cloud.storage.Volume.Type;
@@ -143,7 +142,6 @@ import com.cloud.storage.dao.VMTemplateS3Dao;
 import com.cloud.storage.dao.VMTemplateSwiftDao;
 import com.cloud.storage.dao.VolumeDao;
 import com.cloud.storage.dao.VolumeHostDao;
-import com.cloud.storage.DiskOfferingVO;
 import com.cloud.storage.download.DownloadMonitor;
 import com.cloud.storage.listener.StoragePoolMonitor;
 import com.cloud.storage.listener.VolumeStateListener;
@@ -1885,36 +1883,4 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C
         return null;
     }
 
-    // get bytesRate from disk_offering and vm.disk.throttling.bytes_rate
-    @Override
-    public Long getDiskBytesRate(ServiceOfferingVO offering, DiskOfferingVO diskOffering) {
-        if ((offering != null) && (offering.getBytesRate() > 0)) {
-            return offering.getBytesRate();
-        } else if ((diskOffering != null) && (diskOffering.getBytesRate() > 0)) {
-            return diskOffering.getBytesRate();
-        } else {
-            Long bytesRate = Long.parseLong(_configDao.getValue(Config.VmDiskThrottlingBytesRate.key()));
-            if (bytesRate > 0)  {
-                return bytesRate;
-            }
-        }
-        return 0L;
-    }
-
-    // get iopsRate from disk_offering and vm.disk.throttling.io_rate
-    @Override
-    public Long getDiskIORate(ServiceOfferingVO offering, DiskOfferingVO diskOffering) {
-        if ((offering != null) && (offering.getIopsRate() > 0)) {
-            return offering.getIopsRate();
-        } else if ((diskOffering != null) && (diskOffering.getIopsRate() > 0)) {
-            return diskOffering.getIopsRate();
-        } else {
-            Long iopsRate = Long.parseLong(_configDao.getValue(Config.VmDiskThrottlingIORate.key()));
-            if (iopsRate > 0)  {
-                return iopsRate;
-            }
-        }
-        return 0L;
-    }
-
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/storage/VolumeManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/storage/VolumeManagerImpl.java b/server/src/com/cloud/storage/VolumeManagerImpl.java
index 63f3254..43f3681 100644
--- a/server/src/com/cloud/storage/VolumeManagerImpl.java
+++ b/server/src/com/cloud/storage/VolumeManagerImpl.java
@@ -115,7 +115,6 @@ import com.cloud.server.ManagementServer;
 import com.cloud.service.ServiceOfferingVO;
 import com.cloud.service.dao.ServiceOfferingDao;
 import com.cloud.storage.Storage.ImageFormat;
-import com.cloud.storage.StorageManager;
 import com.cloud.storage.Storage.StoragePoolType;
 import com.cloud.storage.Volume.Event;
 import com.cloud.storage.Volume.Type;
@@ -337,9 +336,6 @@ public class VolumeManagerImpl extends ManagerBase implements VolumeManager {
                 diskOffering.getUseLocalStorage(),
                 diskOffering.isRecreatable(), null);
         dskCh.setHyperType(dataDiskHyperType);
-        dskCh.setBytesRate(storageMgr.getDiskBytesRate(null, diskOffering));
-        dskCh.setIopsRate(storageMgr.getDiskIORate(null, diskOffering));
-
         DataCenterVO destPoolDataCenter = _dcDao.findById(destPoolDcId);
         HostPodVO destPoolPod = _podDao.findById(destPoolPodId);
         
@@ -515,8 +511,6 @@ public class VolumeManagerImpl extends ManagerBase implements VolumeManager {
         DataCenterVO dc = _dcDao.findById(volume.getDataCenterId());
         DiskProfile dskCh = new DiskProfile(volume, diskOffering,
                 snapshot.getHypervisorType());
-        dskCh.setBytesRate(storageMgr.getDiskBytesRate(null, diskOffering));
-        dskCh.setIopsRate(storageMgr.getDiskIORate(null, diskOffering));
 
         // Determine what pod to store the volume in
         while ((pod = _resourceMgr.findPod(null, null, dc, account.getId(),
@@ -617,8 +611,6 @@ public class VolumeManagerImpl extends ManagerBase implements VolumeManager {
         DiskProfile dskCh = createDiskCharacteristics(volume, template, dc,
                 diskOffering);
         dskCh.setHyperType(vm.getHypervisorType());
-        dskCh.setBytesRate(storageMgr.getDiskBytesRate(offering, diskOffering));
-        dskCh.setIopsRate(storageMgr.getDiskIORate(offering, diskOffering));
         // Find a suitable storage to create volume on
         StoragePool destPool = storageMgr.findStoragePool(dskCh, dc, pod,
                 clusterId, null, vm, avoidPools);
@@ -663,8 +655,6 @@ public class VolumeManagerImpl extends ManagerBase implements VolumeManager {
         }
 
         dskCh.setHyperType(hyperType);
-        dskCh.setBytesRate(storageMgr.getDiskBytesRate(offering, diskOffering));
-        dskCh.setIopsRate(storageMgr.getDiskIORate(offering, diskOffering));
         
         final HashSet<StoragePool> avoidPools = new HashSet<StoragePool>(
                 avoids);
@@ -2242,12 +2232,7 @@ public class VolumeManagerImpl extends ManagerBase implements VolumeManager {
 
         for (VolumeVO vol : vols) {
             PrimaryDataStoreInfo pool = (PrimaryDataStoreInfo)this.dataStoreMgr.getDataStore(vol.getPoolId(), DataStoreRole.Primary);
-            ServiceOfferingVO offering = _offeringDao.findById(vm.getServiceOfferingId());
-            DiskOfferingVO diskOffering = _diskOfferingDao.findById(vol.getDiskOfferingId());
-            VolumeTO newVolume = new VolumeTO(vol, pool);
-            newVolume.setBytesRate(storageMgr.getDiskBytesRate(offering, diskOffering));
-            newVolume.setIopsRate(storageMgr.getDiskIORate(offering, diskOffering));
-            vm.addDisk(newVolume);
+            vm.addDisk(new VolumeTO(vol, pool));
         }
 
         if (vm.getType() == VirtualMachine.Type.User) {
@@ -2477,12 +2462,7 @@ public class VolumeManagerImpl extends ManagerBase implements VolumeManager {
                 pool = (StoragePool)dataStoreMgr.getDataStore(result.second().getId(), DataStoreRole.Primary);
                 vol = result.first();
             }
-            ServiceOfferingVO offering = _offeringDao.findById(vm.getServiceOfferingId());
-            DiskOfferingVO diskOffering = _diskOfferingDao.findById(vol.getDiskOfferingId());
-            VolumeTO newVolume = new VolumeTO(vol, pool);
-            newVolume.setBytesRate(storageMgr.getDiskBytesRate(offering, diskOffering));
-            newVolume.setIopsRate(storageMgr.getDiskIORate(offering, diskOffering));
-            vm.addDisk(newVolume);
+            vm.addDisk(new VolumeTO(vol, pool));
         }
     }
     

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/test/DatabaseConfig.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/test/DatabaseConfig.java b/server/src/com/cloud/test/DatabaseConfig.java
index 16829f8..70c8178 100755
--- a/server/src/com/cloud/test/DatabaseConfig.java
+++ b/server/src/com/cloud/test/DatabaseConfig.java
@@ -967,12 +967,6 @@ public class DatabaseConfig {
         }
         DiskOfferingVO diskOffering = new DiskOfferingVO(domainId, name, displayText, diskSpace , tags, false);
         diskOffering.setUseLocalStorage(local);
-        Long bytesRate = Long.parseLong(_currentObjectParams.get("bytesRate"));
-        if (bytesRate != null && (bytesRate > 0))
-            diskOffering.setBytesRate(bytesRate);
-        Long iopsRate = Long.parseLong(_currentObjectParams.get("iopsRate"));
-        if (iopsRate != null && (iopsRate > 0))
-            diskOffering.setIopsRate(iopsRate);
         DiskOfferingDaoImpl offering = ComponentContext.inject(DiskOfferingDaoImpl.class);
         try {
             offering.persist(diskOffering);

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/src/com/cloud/vm/VirtualMachineManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/vm/VirtualMachineManagerImpl.java b/server/src/com/cloud/vm/VirtualMachineManagerImpl.java
index 971de56..568fe55 100755
--- a/server/src/com/cloud/vm/VirtualMachineManagerImpl.java
+++ b/server/src/com/cloud/vm/VirtualMachineManagerImpl.java
@@ -1328,7 +1328,7 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac
             throw new CloudRuntimeException("Unable to migrate vm: " + e.toString());
         }
 
-        VirtualMachineProfile<T> profile = new VirtualMachineProfileImpl<T>(vm);
+        VirtualMachineProfile<VMInstanceVO> profile = new VirtualMachineProfileImpl<VMInstanceVO>(vm);
         boolean migrationResult = false;
         try {
             migrationResult = this.volumeMgr.storageMigration(profile, destPool);

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java b/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java
index 686040b..21b3590 100755
--- a/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java
+++ b/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java
@@ -489,7 +489,7 @@ public class MockConfigurationManagerImpl extends ManagerBase implements Configu
      */
     @Override
     public ServiceOfferingVO createServiceOffering(long userId, boolean isSystem, Type vm_typeType, String name, int cpu, int ramSize, int speed, String displayText, boolean localStorageRequired, boolean offerHA,
-            boolean limitResourceUse, boolean volatileVm, String tags, Long domainId, String hostTag, Integer networkRate, String deploymentPlanner, Map<String, String> details, Long bytesRate, Long iopsRate) {
+            boolean limitResourceUse, boolean volatileVm, String tags, Long domainId, String hostTag, Integer networkRate, String deploymentPlanner, Map<String, String> details) {
         // TODO Auto-generated method stub
         return null;
     }
@@ -654,7 +654,7 @@ public class MockConfigurationManagerImpl extends ManagerBase implements Configu
      * @see com.cloud.configuration.ConfigurationManager#createDiskOffering(java.lang.Long, java.lang.String, java.lang.String, java.lang.Long, java.lang.String, boolean, boolean, boolean)
      */
     @Override
-    public DiskOfferingVO createDiskOffering(Long domainId, String name, String description, Long numGibibytes, String tags, boolean isCustomized, boolean localStorageRequired, boolean isDisplayOfferingEnabled, Long bytesRate, Long iopsRate) {
+    public DiskOfferingVO createDiskOffering(Long domainId, String name, String description, Long numGibibytes, String tags, boolean isCustomized, boolean localStorageRequired, boolean isDisplayOfferingEnabled) {
         // TODO Auto-generated method stub
         return null;
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/setup/db/db/schema-410to420.sql
----------------------------------------------------------------------
diff --git a/setup/db/db/schema-410to420.sql b/setup/db/db/schema-410to420.sql
index a59cf1c..bcfbcc9 100644
--- a/setup/db/db/schema-410to420.sql
+++ b/setup/db/db/schema-410to420.sql
@@ -290,10 +290,6 @@ ALTER TABLE `cloud`.`nics` ADD COLUMN `display_nic` tinyint(1) NOT NULL DEFAULT
 
 ALTER TABLE `cloud`.`disk_offering` ADD COLUMN `display_offering` tinyint(1) NOT NULL DEFAULT 1 COMMENT 'Should disk offering be displayed to the end user';
 
-ALTER TABLE `cloud`.`disk_offering` ADD COLUMN `bytes_rate` bigint(20) unsigned DEFAULT 0;
-
-ALTER TABLE `cloud`.`disk_offering` ADD COLUMN `iops_rate` bigint(20) unsigned DEFAULT 0;
-
 CREATE TABLE `cloud`.`volume_details` (
   `id` bigint unsigned NOT NULL auto_increment,
   `volume_id` bigint unsigned NOT NULL COMMENT 'volume id',
@@ -766,8 +762,6 @@ CREATE VIEW `cloud`.`volume_view` AS
         disk_offering.display_text disk_offering_display_text,
         disk_offering.use_local_storage,
         disk_offering.system_use,
-        disk_offering.bytes_rate,
-        disk_offering.iops_rate,
         storage_pool.id pool_id,
         storage_pool.uuid pool_uuid,
         storage_pool.name pool_name,
@@ -1076,8 +1070,6 @@ CREATE VIEW `cloud`.`service_offering_view` AS
         disk_offering.removed,
         disk_offering.use_local_storage,
         disk_offering.system_use,
-        disk_offering.bytes_rate,
-        disk_offering.iops_rate,
         service_offering.cpu,
         service_offering.speed,
         service_offering.ram_size,
@@ -1384,8 +1376,6 @@ CREATE VIEW `cloud`.`disk_offering_view` AS
         disk_offering.removed,
         disk_offering.use_local_storage,
         disk_offering.system_use,
-        disk_offering.bytes_rate,
-        disk_offering.iops_rate,
         disk_offering.sort_key,
         disk_offering.type,
 	disk_offering.display_offering,
@@ -1626,8 +1616,6 @@ CREATE VIEW `cloud`.`volume_view` AS
         disk_offering.display_text disk_offering_display_text,
         disk_offering.use_local_storage,
         disk_offering.system_use,
-        disk_offering.bytes_rate,
-        disk_offering.iops_rate,
         storage_pool.id pool_id,
         storage_pool.uuid pool_uuid,
         storage_pool.name pool_name,
@@ -1858,8 +1846,7 @@ CREATE TABLE `cloud_usage`.`usage_vm_disk` (
 ) ENGINE=InnoDB CHARSET=utf8;
 
 INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'vm.disk.stats.interval', 0, 'Interval (in seconds) to report vm disk statistics.');
-INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'vm.disk.throttling.iops_rate', 0, 'Default disk I/O rate in requests per second allowed in User vm\'s disk. ');
-INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'vm.disk.throttling.bytes_rate', 0, 'Default disk I/O rate in bytes per second allowed in User vm\'s disk. ');
+
 
 -- Re-enable foreign key checking, at the end of the upgrade path
 SET foreign_key_checks = 1;

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/ui/dictionary.jsp
----------------------------------------------------------------------
diff --git a/ui/dictionary.jsp b/ui/dictionary.jsp
index 13206c3..d7f7dd5 100644
--- a/ui/dictionary.jsp
+++ b/ui/dictionary.jsp
@@ -469,8 +469,6 @@ dictionary = {
 'label.disable.vpn': '<fmt:message key="label.disable.vpn" />',
 'label.disabling.vpn.access': '<fmt:message key="label.disabling.vpn.access" />',
 'label.disk.allocated': '<fmt:message key="label.disk.allocated" />',
-'label.disk.bytes.rate': '<fmt:message key="label.disk.bytes.rate" />',
-'label.disk.iops.rate': '<fmt:message key="label.disk.iops.rate" />',
 'label.disk.read.bytes': '<fmt:message key="label.disk.read.bytes" />',
 'label.disk.read.io': '<fmt:message key="label.disk.read.io" />',
 'label.disk.offering': '<fmt:message key="label.disk.offering" />',

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/ui/scripts/configuration.js
----------------------------------------------------------------------
diff --git a/ui/scripts/configuration.js b/ui/scripts/configuration.js
index daed97a..8a4aa7d 100644
--- a/ui/scripts/configuration.js
+++ b/ui/scripts/configuration.js
@@ -109,20 +109,6 @@
                       number: true
                     }
                   },
-                  diskBytesRate: {
-                	  label: 'label.disk.bytes.rate',
-                      validation: {
-                        required: false, //optional
-                        number: true
-                      }
-                  },
-                  diskIORate: {
-                	  label: 'label.disk.iops.rate',
-                      validation: {
-                        required: false, //optional
-                        number: true
-                      }
-                  },
                   offerHA: {
                     label: 'label.offer.ha',
                     docID: 'helpComputeOfferingHA',
@@ -241,16 +227,6 @@
 									  networkrate: args.data.networkRate
 									});
 								}
-                if(args.data.diskBytesRate != null && args.data.diskBytesRate.length > 0) {
-                                                                  $.extend(data, {
-                                                                          bytesRate: args.data.diskBytesRate
-                                                                        });
-                                                                }
-                if(args.data.diskIORate != null && args.data.diskIORate.length > 0) {
-                                                                  $.extend(data, {
-                                                                          iopsRate: args.data.diskIORate
-                                                                        });
-                                                                }
 
                 $.extend(data, {
                   offerha: (args.data.offerHA == "on")
@@ -420,8 +396,6 @@
                       }
                     },
                     networkrate: { label: 'label.network.rate' },
-                    diskBytesRate: { label: 'label.disk.bytes.rate' },
-                    diskIORate: { label: 'label.disk.iops.rate' },
                     offerha: {
                       label: 'label.offer.ha',
                       converter: cloudStack.converters.toBooleanText
@@ -560,20 +534,6 @@
                       number: true
                     }
                   },
-                  diskBytesRate: {
-                	  label: 'label.disk.bytes.rate',
-                      validation: {
-                        required: false, //optional
-                        number: true
-                      }
-                  },
-                  diskIORate: {
-                	  label: 'label.disk.iops.rate',
-                      validation: {
-                        required: false, //optional
-                        number: true
-                      }
-                  },
                   offerHA: {
                     label: 'label.offer.ha',
                     docID: 'helpSystemOfferingHA',
@@ -642,16 +602,6 @@
 									  networkrate: args.data.networkRate
 									});								
 								}
-                if(args.data.diskBytesRate != null && args.data.diskBytesRate.length > 0) {
-                                                                  $.extend(data, {
-                                                                          bytesRate: args.data.diskBytesRate
-                                                                        });
-                                                                }
-                if(args.data.diskIORate != null && args.data.diskIORate.length > 0) {
-                                                                  $.extend(data, {
-                                                                          iopsRate: args.data.diskIORate
-                                                                        });
-                                                                }
 
 								$.extend(data, {
 								  offerha: (args.data.offerHA == "on")
@@ -831,8 +781,6 @@
                       }
                     },
                     networkrate: { label: 'label.network.rate' },
-                    diskBytesRate: { label: 'label.disk.bytes.rate' },
-                    diskIORate: { label: 'label.disk.iops.rate' },
                     offerha: {
                       label: 'label.offer.ha',
                       converter: cloudStack.converters.toBooleanText
@@ -892,20 +840,6 @@
                 else
                   return "N/A";
               }
-            },
-            diskBytesRate: {
-          	  label: 'label.disk.bytes.rate',
-                validation: {
-                  required: false, //optional
-                  number: true
-                }
-            },
-            diskIORate: {
-          	  label: 'label.disk.iops.rate',
-                validation: {
-                  required: false, //optional
-                  number: true
-                }
             }
           },
 
@@ -977,20 +911,6 @@
                     dependsOn: 'isCustomized',
                     validation: { required: true, number: true }
                   },
-                  diskBytesRate: {
-                	  label: 'label.disk.bytes.rate',
-                      validation: {
-                        required: false, //optional
-                        number: true
-                      }
-                  },
-                  diskIORate: {
-                	  label: 'label.disk.iops.rate',
-                      validation: {
-                        required: false, //optional
-                        number: true
-                      }
-                  },
                   tags: {
                     label: 'label.storage.tags',
                     docID: 'helpDiskOfferingStorageTags'
@@ -1164,8 +1084,6 @@
                           return "N/A";
                       }
                     },
-                    diskBytesRate: { label: 'label.disk.bytes.rate' },
-                    diskIORate: { label: 'label.disk.iops.rate' },
                     tags: { label: 'label.storage.tags' },
                     domain: { label: 'label.domain' },
                     storagetype: { label: 'label.storage.type' }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f714d260/ui/scripts/instances.js
----------------------------------------------------------------------
diff --git a/ui/scripts/instances.js b/ui/scripts/instances.js
index 99b1a0f..6a589ba 100644
--- a/ui/scripts/instances.js
+++ b/ui/scripts/instances.js
@@ -1669,8 +1669,8 @@
                   networkkbswrite: (jsonObj.networkkbswrite == null)? "N/A": cloudStack.converters.convertBytes(jsonObj.networkkbswrite * 1024),
                   diskkbsread: (jsonObj.diskkbsread == null)? "N/A": cloudStack.converters.convertBytes(jsonObj.diskkbsread * 1024),
                   diskkbswrite: (jsonObj.diskkbswrite == null)? "N/A": cloudStack.converters.convertBytes(jsonObj.diskkbswrite * 1024),
-                  diskioread: (jsonObj.diskioread == null)? "N/A": jsonObj.diskioread,
-                  diskiowrite: (jsonObj.diskiowrite == null)? "N/A": jsonObj.diskiowrite
+                  diskioread: (jsonObj.diskioread == null)? "N/A": cloudStack.converters.convertBytes(jsonObj.diskioread * 1024),
+                  diskiowrite: (jsonObj.diskiowrite == null)? "N/A": cloudStack.converters.convertBytes(jsonObj.diskiowrite * 1024)
                   }
                 });
               }


Mime
View raw message