You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by GitBox <gi...@apache.org> on 2021/07/27 04:42:35 UTC

[GitHub] [libcloud] palashgandhi opened a new pull request #1596: EC2: Add support for gp3 and io2 volumes

palashgandhi opened a new pull request #1596:
URL: https://github.com/apache/libcloud/pull/1596


   ## EC2: Add support for gp3 and io2 volumes
   
   ### Description
   
   The ec2 driver currently supports `standard`, `io1`, `gp2`, `st1` and `sc1` volume types. This change adds support for `gp3` and `io2` volume types. The driver currently maintains a list of volume types and raises a `ValueError` if an unsupported volume type is passed. The solution is to simply add the new types to this list. This change also enhances the `create_volume` unit test to verify that a `ValueError` is raised for a volume type that is not in the list.
   
   ### Status
   
   - done, ready for review
   
   ### Checklist (tick everything that applies)
   
   - [x] [Code linting](http://libcloud.readthedocs.org/en/latest/development.html#code-style-guide) (required, can be done after the PR checks)
   - [x] Documentation
   - [x] [Tests](http://libcloud.readthedocs.org/en/latest/testing.html)
   - [x] [ICLA](http://libcloud.readthedocs.org/en/latest/development.html#contributing-bigger-changes) (required for bigger changes)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@libcloud.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [libcloud] codecov-commenter commented on pull request #1596: EC2: Add support for gp3 and io2 volumes

Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on pull request #1596:
URL: https://github.com/apache/libcloud/pull/1596#issuecomment-887205122


   # [Codecov](https://codecov.io/gh/apache/libcloud/pull/1596?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#1596](https://codecov.io/gh/apache/libcloud/pull/1596?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (7d281e1) into [trunk](https://codecov.io/gh/apache/libcloud/commit/ea364c58cd954d6b076c4e30bb283f33381a1246?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (ea364c5) will **increase** coverage by `0.00%`.
   > The diff coverage is `100.00%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/libcloud/pull/1596/graphs/tree.svg?width=650&height=150&src=pr&token=PYoduksh69&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/libcloud/pull/1596?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@           Coverage Diff           @@
   ##            trunk    #1596   +/-   ##
   =======================================
     Coverage   83.01%   83.01%           
   =======================================
     Files         394      394           
     Lines       84999    85001    +2     
     Branches     9040     9040           
   =======================================
   + Hits        70558    70562    +4     
   + Misses      11374    11373    -1     
   + Partials     3067     3066    -1     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/libcloud/pull/1596?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [libcloud/compute/drivers/ec2.py](https://codecov.io/gh/apache/libcloud/pull/1596/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-bGliY2xvdWQvY29tcHV0ZS9kcml2ZXJzL2VjMi5weQ==) | `75.58% <100.00%> (+0.12%)` | :arrow_up: |
   | [libcloud/test/compute/test\_ec2.py](https://codecov.io/gh/apache/libcloud/pull/1596/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-bGliY2xvdWQvdGVzdC9jb21wdXRlL3Rlc3RfZWMyLnB5) | `97.88% <100.00%> (+<0.01%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/libcloud/pull/1596?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/libcloud/pull/1596?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [ea364c5...7d281e1](https://codecov.io/gh/apache/libcloud/pull/1596?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@libcloud.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [libcloud] tonynguien commented on a change in pull request #1596: EC2: Add support for gp3 and io2 volumes

Posted by GitBox <gi...@apache.org>.
tonynguien commented on a change in pull request #1596:
URL: https://github.com/apache/libcloud/pull/1596#discussion_r678461808



##########
File path: libcloud/compute/drivers/ec2.py
##########
@@ -2157,6 +2163,9 @@ def create_volume(self, size, name, location=None, snapshot=None,
             if ex_kms_key_id is not None:
                 params['KmsKeyId'] = ex_kms_key_id
 
+        if ex_volume_type == 'gp3' and ex_throughput:

Review comment:
       You're right. We can't set throughput for io1 and io2 volumes, i.e. AWS Console volume modify doesn't have a throughput change option.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@libcloud.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [libcloud] tonynguien commented on a change in pull request #1596: EC2: Add support for gp3 and io2 volumes

Posted by GitBox <gi...@apache.org>.
tonynguien commented on a change in pull request #1596:
URL: https://github.com/apache/libcloud/pull/1596#discussion_r677907050



##########
File path: libcloud/compute/drivers/ec2.py
##########
@@ -2157,6 +2163,9 @@ def create_volume(self, size, name, location=None, snapshot=None,
             if ex_kms_key_id is not None:
                 params['KmsKeyId'] = ex_kms_key_id
 
+        if ex_volume_type == 'gp3' and ex_throughput:

Review comment:
       I believe we want to allow caller to specify throughput for io1 and io2 volume types, similar to iops.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@libcloud.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [libcloud] palashgandhi commented on a change in pull request #1596: EC2: Add support for gp3 and io2 volumes

Posted by GitBox <gi...@apache.org>.
palashgandhi commented on a change in pull request #1596:
URL: https://github.com/apache/libcloud/pull/1596#discussion_r677936152



##########
File path: libcloud/compute/drivers/ec2.py
##########
@@ -2157,6 +2163,9 @@ def create_volume(self, size, name, location=None, snapshot=None,
             if ex_kms_key_id is not None:
                 params['KmsKeyId'] = ex_kms_key_id
 
+        if ex_volume_type == 'gp3' and ex_throughput:

Review comment:
       According to the [EC2 API reference](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateVolume.html):
   
   >  Throughput
   > The throughput to provision for a volume, with a maximum of 1,000 MiB/s.
   > This parameter is valid only for gp3 volumes. 
   
   Are you seeing different behavior i.e. are you able to actually set the throughput for a volume type other than `gp3`? If so, the API reference might be outdated.
   
   Regarding iops, my change already has the following logic that should allow you to set `Iops` for io1, io2 and gp3 volumes:
   ```
       if ex_volume_type in ['io1', 'io2', 'gp3'] and ex_iops:
               params['Iops'] = ex_iops
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@libcloud.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [libcloud] asfgit merged pull request #1596: EC2: Add support for gp3 and io2 volumes

Posted by GitBox <gi...@apache.org>.
asfgit merged pull request #1596:
URL: https://github.com/apache/libcloud/pull/1596


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@libcloud.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [libcloud] Kami commented on pull request #1596: EC2: Add support for gp3 and io2 volumes

Posted by GitBox <gi...@apache.org>.
Kami commented on pull request #1596:
URL: https://github.com/apache/libcloud/pull/1596#issuecomment-949423521


   Merged, thanks.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@libcloud.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org