{"action":"opened","issue":{"url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3119","repository_url":"https://api.github.com/repos/ansible/ansible-modules-core","labels_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3119/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3119/comments","events_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3119/events","html_url":"https://github.com/ansible/ansible-modules-core/issues/3119","id":136427344,"number":3119,"title":"elasticache module not idempotent: Fails if cluster already exists","user":{"login":"njsaunders","id":1478320,"avatar_url":"https://avatars.githubusercontent.com/u/1478320?v=3","gravatar_id":"","url":"https://api.github.com/users/njsaunders","html_url":"https://github.com/njsaunders","followers_url":"https://api.github.com/users/njsaunders/followers","following_url":"https://api.github.com/users/njsaunders/following{/other_user}","gists_url":"https://api.github.com/users/njsaunders/gists{/gist_id}","starred_url":"https://api.github.com/users/njsaunders/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/njsaunders/subscriptions","organizations_url":"https://api.github.com/users/njsaunders/orgs","repos_url":"https://api.github.com/users/njsaunders/repos","events_url":"https://api.github.com/users/njsaunders/events{/privacy}","received_events_url":"https://api.github.com/users/njsaunders/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-02-25T15:52:19Z","updated_at":"2016-02-25T15:52:19Z","closed_at":null,"body":"##### Issue Type:\r\n\r\n - Bug Report\r\n\r\n##### Plugin Name:\r\n\r\nelasticache\r\n\r\n##### Ansible Version:\r\n\r\n```\r\nansible 2.1.0\r\n  config file =\r\n  configured module search path = Default w/o overrides\r\n```\r\n\r\n##### Ansible Configuration:\r\n\r\nDefault\r\n\r\n##### Environment:\r\n\r\nN/A\r\n\r\n##### Summary:\r\n\r\nThe elasticache module correctly creates an elasticache cluster, but running the same playbook again fails it if the cluster already exists.\r\n\r\n##### Steps To Reproduce:\r\n\r\n<!-- For bugs, please show exactly how to reproduce the problem.\r\nFor new features, show how the feature would be used.  -->\r\n\r\n```\r\n    - name: Create Elasticache node\r\n      elasticache:\r\n        name: \"my-cluster\"\r\n        state: present\r\n        engine: memcached\r\n        node_type: cache.t2.small\r\n        num_nodes: 1\r\n        cache_port: 11112\r\n        wait: no\r\n        hard_modify: no\r\n        region: \"us-west-2\"\r\n        cache_subnet_group: \"my-subnet-group\"\r\n        security_group_ids: [\"sg-1234567\"]\r\n```\r\n\r\n##### Expected Results:\r\n\r\nRunning the above repeatedly should succeed with the first execution creating the cluster and subsequent executions seeing that it exists and moving on\r\n\r\n##### Actual Results:\r\n\r\nRunning the above twice fails with the error:\r\n\r\n```\r\nTASK [Create Elasticache node] *************************************************\r\nfatal: [127.0.0.1]: FAILED! => {\"changed\": false, \"failed\": true, \"msg\": \"Cache cluster already exists\"}\r\n```\r\n"}}