Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ec2_vol_info ignores throughput parameter of gp3 volume type #367

Closed
RomanDanyk opened this issue May 12, 2021 · 3 comments
Closed

ec2_vol_info ignores throughput parameter of gp3 volume type #367

RomanDanyk opened this issue May 12, 2021 · 3 comments
Labels
bug This issue/PR relates to a bug has_pr module module python3

Comments

@RomanDanyk
Copy link

SUMMARY

The ec2_vol_info module ignores the throughput parameter of gp3 volume type

ISSUE TYPE
  • Bug Report
COMPONENT NAME

ec2_vol_info

ANSIBLE VERSION
ansible 2.10.6
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/roman/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /home/roman/.local/lib/python3.8/site-packages/ansible
  executable location = /home/roman/.local/bin/ansible
  python version = 3.8.5 (default, Jan 27 2021, 15:41:15) [GCC 9.3.0]
CONFIGURATION

STEPS TO REPRODUCE
---
- hosts: default
  tasks:

    - name: gather facts about the volume
      amazon.aws.ec2_vol_info:
        filters:
          attachment.status: attached
          "tag:Name": test-volume
      register: vol_facts

    - name: print out facts
      debug:
        var: vol_facts
EXPECTED RESULTS

Gathered facts include information about the volume throughput (for gp3 volume type):

{
    "vol_facts": {
        "changed": false,
        "failed": false,
        "volumes": [
            {
                "attachment_set": {
                    "attach_time": "2021-05-11T12:57:58+00:00",
                    "delete_on_termination": true,
                    "device": "/dev/sda1",
                    "instance_id": "i-0709abe4a9d547fca",
                    "status": "attached"
                },
                "create_time": "2021-05-11T12:57:59.049000+00:00",
                "encrypted": true,
                "id": "vol-0b6d3beb87d33b42f",
                "iops": 3000,
                "region": "eu-west-1",
                "size": 60,
                "snapshot_id": "snap-0925edc1a303cc79c",
                "status": "in-use",
                "tags": {
                    "Name": "test-volume"
                },
                "throughput": 125,
                "type": "gp3",
                "zone": "eu-west-1a"
            }
        ]
    }
}
ACTUAL RESULTS

The throughput parameter is ignored in the get_volume_info function:

{
    "vol_facts": {
        "changed": false,
        "failed": false,
        "volumes": [
            {
                "attachment_set": {
                    "attach_time": "2021-05-11T12:57:58+00:00",
                    "delete_on_termination": true,
                    "device": "/dev/sda1",
                    "instance_id": "i-0709abe4a9d547fca",
                    "status": "attached"
                },
                "create_time": "2021-05-11T12:57:59.049000+00:00",
                "encrypted": true,
                "id": "vol-0b6d3beb87d33b42f",
                "iops": 3000,
                "region": "eu-west-1",
                "size": 60,
                "snapshot_id": "snap-0925edc1a303cc79c",
                "status": "in-use",
                "tags": {
                    "Name": "test-volume"
                },
                "type": "gp3",
                "zone": "eu-west-1a"
            }
        ]
    }
}
@abikouo
Copy link
Contributor

abikouo commented May 14, 2021

@RomanDanyk thanks for taking the time to report this issue.
It has also been addressed into this PR adding new feature to the ec2_vol and ec2_vol_info
#365
Feel free to test it locally

@abikouo abikouo added the has_pr label May 14, 2021
@ansibullbot
Copy link

@ansibullbot ansibullbot added bug This issue/PR relates to a bug module module python3 labels May 21, 2021
@alinabuzachis
Copy link
Contributor

I am closing the issue as it has been addressed and merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue/PR relates to a bug has_pr module module python3
Projects
None yet
Development

No branches or pull requests

4 participants