[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-12-06 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16712011#comment-16712011
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

svenvogel commented on issue #2231: [CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#issuecomment-445023790
 
 
   @syed is it useful for solidfire? Is there any progress in this pr?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-11-29 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16703657#comment-16703657
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

bwsw commented on issue #2231: [CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#issuecomment-442953563
 
 
   @syed Hi, do you continue to manage this PR? I think it's very beneficial 
for 4.12.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374914#comment-16374914
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170353521
 
 

 ##
 File path: 
server/src/main/java/com/cloud/configuration/ConfigurationManagerImpl.java
 ##
 @@ -2566,6 +2567,61 @@ protected DiskOfferingVO createDiskOffering(final Long 
userId, final Long domain
 isCustomized = true;
 }
 
+if (minIopsPerGb != null || maxIopsPerGb != null) {
+
+if (!isCustomized) {
+   throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB for a fixed size disk offering");
 
 Review comment:
   So, for fixed size disks we cannot control the IOPS?  Why cannot we 
control/limit the IOPS of fixed size disks?
   
   BTW, what do you understand as IOPS? input and output per second, meaning 
read and write speed.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374909#comment-16374909
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170353027
 
 

 ##
 File path: engine/schema/src/main/resources/META-INF/db/schema-41100to41200.sql
 ##
 @@ -0,0 +1,70 @@
+-- IOPS per GB disk offering
+DROP PROCEDURE IF EXISTS `cloud`.`ADD_COLUMN_TO_TABLE_IDEMPOTENT`;
+
+DELIMITER //
+CREATE PROCEDURE `cloud`.`ADD_COLUMN_TO_TABLE_IDEMPOTENT`(
 
 Review comment:
   Hmm.. Then, I think it is better to coordinate with PR #2449.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374905#comment-16374905
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

syed commented on a change in pull request #2231: [CLOUDSTACK-10039] Adding 
IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170351240
 
 

 ##
 File path: 
server/src/main/java/com/cloud/configuration/ConfigurationManagerImpl.java
 ##
 @@ -2566,6 +2567,61 @@ protected DiskOfferingVO createDiskOffering(final Long 
userId, final Long domain
 isCustomized = true;
 }
 
+if (minIopsPerGb != null || maxIopsPerGb != null) {
+
+if (!isCustomized) {
+   throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB for a fixed size disk offering");
 
 Review comment:
   You cannot have an IOPS/GB offering for a fixed sized disk. The whole Idea 
of an IOPS/GB type of offering makes sense when you have a custom offering so 
when you change the size of a disk, the IOPS also change


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374903#comment-16374903
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

syed commented on a change in pull request #2231: [CLOUDSTACK-10039] Adding 
IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170350998
 
 

 ##
 File path: engine/schema/src/main/resources/META-INF/db/schema-41100to41200.sql
 ##
 @@ -0,0 +1,70 @@
+-- IOPS per GB disk offering
+DROP PROCEDURE IF EXISTS `cloud`.`ADD_COLUMN_TO_TABLE_IDEMPOTENT`;
+
+DELIMITER //
+CREATE PROCEDURE `cloud`.`ADD_COLUMN_TO_TABLE_IDEMPOTENT`(
 
 Review comment:
   No. This is only for this PR


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374677#comment-16374677
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170312130
 
 

 ##
 File path: setup/db/db/schema-41000to41100.sql
 ##
 @@ -0,0 +1,324 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
 
 Review comment:
   these scripts should not be here, right?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374672#comment-16374672
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170310191
 
 

 ##
 File path: 
server/src/main/java/com/cloud/configuration/ConfigurationManagerImpl.java
 ##
 @@ -2566,6 +2567,61 @@ protected DiskOfferingVO createDiskOffering(final Long 
userId, final Long domain
 isCustomized = true;
 }
 
+if (minIopsPerGb != null || maxIopsPerGb != null) {
+
+if (!isCustomized) {
+   throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB for a fixed size disk offering");
+}
+
+if ((isCustomizedIops != null && isCustomizedIops) || minIops != 
null || maxIops != null) {
 
 Review comment:
   Can you use BooleanUtils here?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374678#comment-16374678
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170311751
 
 

 ##
 File path: server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java
 ##
 @@ -981,6 +1021,7 @@ public VolumeVO resizeVolume(ResizeVolumeCmd cmd) throws 
ResourceAllocationExcep
 newSize = newDiskOffering.getDiskSize();
 }
 
+newSizeInGb = newSize >> 30;
 
 Review comment:
   bit shift...
   
   Have you checked if there is a library to convert between these bases? If 
there is none, what about we create an utils method to execute this job?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374679#comment-16374679
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170310467
 
 

 ##
 File path: 
server/src/main/java/com/cloud/configuration/ConfigurationManagerImpl.java
 ##
 @@ -2566,6 +2567,61 @@ protected DiskOfferingVO createDiskOffering(final Long 
userId, final Long domain
 isCustomized = true;
 }
 
+if (minIopsPerGb != null || maxIopsPerGb != null) {
+
+if (!isCustomized) {
+   throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB for a fixed size disk offering");
+}
+
+if ((isCustomizedIops != null && isCustomizedIops) || minIops != 
null || maxIops != null) {
+throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB with either " +
+"custom IOPS or fixed IOPS");
+}
+
+if (minIopsPerGb != null && maxIopsPerGb != null) {
+if (minIopsPerGb <= 0 || maxIopsPerGb <= 0) {
+throw new InvalidParameterValueException("Min/Max IOPS/GB 
value must be greater than 0");
+}
+
+if (minIopsPerGb > maxIopsPerGb){
+throw new InvalidParameterValueException("Min IOPS/GB must 
be greater than max IOPS/GB");
+}
+}
+
+//if either one of them is set but the other is not
+if ((minIopsPerGb != null && maxIopsPerGb == null) || 
(minIopsPerGb == null && maxIopsPerGb != null)) {
+throw new InvalidParameterValueException("Both min IOPS/GB and 
max IOPS/GB must be specified");
+}
+}
+
+if (highestMinIops != null && highestMaxIops != null) {
 
 Review comment:
   This whole validation block can also be extracted to a method, documented 
and unit tested.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374674#comment-16374674
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170309607
 
 

 ##
 File path: engine/schema/src/main/resources/META-INF/db/schema-41100to41200.sql
 ##
 @@ -0,0 +1,70 @@
+-- IOPS per GB disk offering
+DROP PROCEDURE IF EXISTS `cloud`.`ADD_COLUMN_TO_TABLE_IDEMPOTENT`;
+
+DELIMITER //
+CREATE PROCEDURE `cloud`.`ADD_COLUMN_TO_TABLE_IDEMPOTENT`(
 
 Review comment:
   Isn't this being introduced by some other PR?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374676#comment-16374676
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170311638
 
 

 ##
 File path: server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java
 ##
 @@ -916,29 +951,34 @@ public VolumeVO resizeVolume(ResizeVolumeCmd cmd) throws 
ResourceAllocationExcep
 // no parameter provided; just use the original size of the 
volume
 newSize = volume.getSize();
 }
-
+newSizeInGb = newSize >> 30;
 
 Review comment:
   Let's not use bit shift here. It makes things harder to read and understand.
   
   The code is already convoluted enough


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374675#comment-16374675
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170310373
 
 

 ##
 File path: 
server/src/main/java/com/cloud/configuration/ConfigurationManagerImpl.java
 ##
 @@ -2566,6 +2567,61 @@ protected DiskOfferingVO createDiskOffering(final Long 
userId, final Long domain
 isCustomized = true;
 }
 
+if (minIopsPerGb != null || maxIopsPerGb != null) {
+
+if (!isCustomized) {
+   throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB for a fixed size disk offering");
+}
+
+if ((isCustomizedIops != null && isCustomizedIops) || minIops != 
null || maxIops != null) {
+throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB with either " +
+"custom IOPS or fixed IOPS");
+}
+
+if (minIopsPerGb != null && maxIopsPerGb != null) {
 
 Review comment:
   Could you extract this block to a specific method? Document it, and write 
unit tests for it?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374673#comment-16374673
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on a change in pull request #2231: 
[CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#discussion_r170310089
 
 

 ##
 File path: 
server/src/main/java/com/cloud/configuration/ConfigurationManagerImpl.java
 ##
 @@ -2566,6 +2567,61 @@ protected DiskOfferingVO createDiskOffering(final Long 
userId, final Long domain
 isCustomized = true;
 }
 
+if (minIopsPerGb != null || maxIopsPerGb != null) {
+
+if (!isCustomized) {
+   throw new InvalidParameterValueException("Cannot set Min/Max 
IOPS/GB for a fixed size disk offering");
 
 Review comment:
   I did not understand this error here. Can you explain it a little further?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16374624#comment-16374624
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

syed commented on issue #2231: [CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#issuecomment-368067578
 
 
   @rafaelweingartner I've resolved the conflicts. I'd really like to get this 
in because I think this is the 3rd time rebasing it. If you could do a code 
review, that would be sublime :)


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-02-22 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16373659#comment-16373659
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rafaelweingartner commented on issue #2231: [CLOUDSTACK-10039] Adding IOPS/GB 
offering
URL: https://github.com/apache/cloudstack/pull/2231#issuecomment-367855144
 
 
   Ping @syed 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
>Priority: Major
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-01-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16309285#comment-16309285
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rhtyd commented on issue #2231: [CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#issuecomment-354958199
 
 
   @syed can you fix the conflicts?
   Additional code review is also requested.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2018-01-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16309284#comment-16309284
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rhtyd commented on issue #2231: [CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#issuecomment-354958199
 
 
   @syed can you fix the conflicts?


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-12-15 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16292679#comment-16292679
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

syed commented on issue #2294: [CLOUDSTACK-10039] Adding allocated IOPS to 
storage pool response
URL: https://github.com/apache/cloudstack/pull/2294#issuecomment-352034337
 
 
   Thanks @rhtyd 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-12-15 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16292445#comment-16292445
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rhtyd closed pull request #2294: [CLOUDSTACK-10039] Adding allocated IOPS to 
storage pool response
URL: https://github.com/apache/cloudstack/pull/2294
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git 
a/api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java 
b/api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java
index 02d5c44a93a..a03c2d8d751 100644
--- a/api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java
+++ b/api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java
@@ -93,6 +93,10 @@
 @Param(description = "IOPS CloudStack can provision from this storage 
pool")
 private Long capacityIops;
 
+@SerializedName("allocatediops")
+@Param(description = "total min IOPS currently in use by volumes")
+private Long allocatedIops;
+
 @SerializedName("tags")
 @Param(description = "the tags for the storage pool")
 private String tags;
@@ -288,6 +292,10 @@ public void setCapacityIops(Long capacityIops) {
 this.capacityIops = capacityIops;
 }
 
+public void setAllocatedIops(Long allocatedIops) {
+   this.allocatedIops = allocatedIops;
+}
+
 public String getTags() {
 return tags;
 }
diff --git a/server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java 
b/server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java
index 37fdaefefcf..b8b312bd267 100644
--- a/server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java
+++ b/server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java
@@ -19,6 +19,7 @@
 import com.cloud.api.ApiDBUtils;
 import com.cloud.api.query.vo.StoragePoolJoinVO;
 import com.cloud.capacity.CapacityManager;
+import com.cloud.storage.DataStoreRole;
 import com.cloud.storage.StoragePool;
 import com.cloud.storage.StorageStats;
 import com.cloud.utils.StringUtils;
@@ -26,7 +27,11 @@
 import com.cloud.utils.db.SearchBuilder;
 import com.cloud.utils.db.SearchCriteria;
 import org.apache.cloudstack.api.response.StoragePoolResponse;
+import org.apache.cloudstack.engine.subsystem.api.storage.DataStore;
+import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreManager;
+import 
org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStoreDriver;
 import org.apache.cloudstack.framework.config.dao.ConfigurationDao;
+import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao;
 import org.apache.log4j.Logger;
 import org.springframework.stereotype.Component;
 
@@ -41,6 +46,12 @@
 @Inject
 private ConfigurationDao _configDao;
 
+@Inject
+private DataStoreManager dataStoreMgr;
+
+@Inject
+protected PrimaryDataStoreDao storagePoolDao;
+
 private final SearchBuilder spSearch;
 
 private final SearchBuilder spIdSearch;
@@ -60,6 +71,7 @@ protected StoragePoolJoinDaoImpl() {
 
 @Override
 public StoragePoolResponse newStoragePoolResponse(StoragePoolJoinVO pool) {
+StoragePool storagePool = storagePoolDao.findById(pool.getId());
 StoragePoolResponse poolResponse = new StoragePoolResponse();
 poolResponse.setId(pool.getUuid());
 poolResponse.setName(pool.getName());
@@ -87,6 +99,13 @@ public StoragePoolResponse 
newStoragePoolResponse(StoragePoolJoinVO pool) {
 poolResponse.setDiskSizeAllocated(allocatedSize);
 poolResponse.setCapacityIops(pool.getCapacityIops());
 
+if (storagePool.isManaged()) {
+DataStore store = dataStoreMgr.getDataStore(pool.getId(), 
DataStoreRole.Primary);
+PrimaryDataStoreDriver driver = (PrimaryDataStoreDriver) 
store.getDriver();
+long usedIops = driver.getUsedIops(storagePool);
+poolResponse.setAllocatedIops(usedIops);
+}
+
 // TODO: StatsCollector does not persist data
 StorageStats stats = ApiDBUtils.getStoragePoolStatistics(pool.getId());
 if (stats != null) {
diff --git a/ui/l10n/en.js b/ui/l10n/en.js
index 39e70727ba1..86134647e0e 100644
--- a/ui/l10n/en.js
+++ b/ui/l10n/en.js
@@ -661,6 +661,7 @@ var dictionary = {"ICMP.code":"ICMP Code",
 "label.disk.iops.min":"Min IOPS",
 "label.disk.iops.read.rate":"Disk Read Rate (IOPS)",
 "label.disk.iops.total":"IOPS Total",
+"label.disk.iops.allocated":"IOPS Allocated",
 "label.disk.iops.write.rate":"Disk Write Rate (IOPS)",
 "label.disk.offering":"Disk Offering",
 "label.disk.offering.details":"Disk offering details",
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index aa7136459e5..d05bfd3132d 1007

[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-12-15 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16292446#comment-16292446
 ] 

ASF subversion and git services commented on CLOUDSTACK-10039:
--

Commit 47419df368336b089814d66f4a70afeae9e1ba47 in cloudstack's branch 
refs/heads/master from [~syed1]
[ https://gitbox.apache.org/repos/asf?p=cloudstack.git;h=47419df ]

CLOUDSTACK-10039: Adding used IOPS to storage pool response (#2294)

This change adds allocatediops to the ListStoragePool API. This applies to 
managed storage where we have a guaranteed minimum IOPS set. This is useful for 
monitoring if we have reached the IOPS limit on a storage cluster.

> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-12-15 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16292444#comment-16292444
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

rhtyd commented on issue #2294: [CLOUDSTACK-10039] Adding allocated IOPS to 
storage pool response
URL: https://github.com/apache/cloudstack/pull/2294#issuecomment-351996474
 
 
   LGTM, merging this now.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-11-12 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16249167#comment-16249167
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

bwsw commented on issue #2231: [CLOUDSTACK-10039] Adding IOPS/GB offering
URL: https://github.com/apache/cloudstack/pull/2231#issuecomment-343830206
 
 
   Cool feature. Recently have thought about it.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-11-07 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16243060#comment-16243060
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

mike-tutkowski commented on issue #2294: [CLOUDSTACK-10039] Adding allocated 
IOPS to storage pool response
URL: https://github.com/apache/cloudstack/pull/2294#issuecomment-342650355
 
 
   Are we good to go with this PR? Should I merge it? Thanks!


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-11-07 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16243059#comment-16243059
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

mike-tutkowski commented on issue #2294: [CLOUDSTACK-10039] Adding allocated 
IOPS to storage pool response
URL: https://github.com/apache/cloudstack/pull/2294#issuecomment-338831054
 
 
   @borisroman Are we good to go with this PR? Should I merge it? Thanks!


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (CLOUDSTACK-10039) Adding IOPS/GB offering

2017-10-23 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-10039?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16216101#comment-16216101
 ] 

ASF GitHub Bot commented on CLOUDSTACK-10039:
-

mike-tutkowski commented on issue #2294: [CLOUDSTACK-10039] Adding allocated 
IOPS to storage pool response
URL: https://github.com/apache/cloudstack/pull/2294#issuecomment-338831054
 
 
   @borisroman Are we good to go with this PR? Should I merge it? Thanks!


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Adding IOPS/GB offering
> ---
>
> Key: CLOUDSTACK-10039
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10039
> Project: CloudStack
>  Issue Type: New Feature
>  Security Level: Public(Anyone can view this level - this is the 
> default.) 
>  Components: Storage Controller
>Reporter: Syed Ahmed
> Fix For: Future
>
>
> We want to add a disk offering where we can specify the Min/Max IOPS as a 
> function of size. The idea is the larger volume you create, the greater your 
> IOPS will be (this is similar to the way GCE handles IOPS). We also have 
> added limits to the IOPS (min and max) so that once the volume goes beyond a 
> certain size, the IOPS won't change and are capped to the given values.
> The following parameters are added to the `createDiskOffering` API:
> 1. `miniopspergb' : Minimum IOPS/GB for the offering
> 2. `maxiopspergb`: Maximum IOPS/GB for the offering
> 3. `highestminiops`: The highest `miniops` value that is allowed for this 
> offering
> 3. `highestmaxiops`: The highest `maxiops` value that is allowed for this 
> offering



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)