GitHub user jbaublitz opened a pull request:
https://github.com/apache/libcloud/pull/974
Bug fix for deletion against asynchronous Google subnetwork API
## Bug fix for `ex_destroy_subnetwork`
### Description
libcloud assumes that the Google subnetwork API is synchronous which does
not appear to be the case. This causes breakage in ansible where the libcloud
API for `ex_destroy_subnetwork` reports that is has successfully destroyed the
subnetwork. Immediate calls to `ex_destroy_network` seem to indicate that the
subnetwork has not been destroyed as the network is reported to still be in use
by the subnetwork. This bug fix is also verified to fix this race condition
that causes ansible to fail when sequentially executing the code in PR
ansible/ansible-modules-core#3773 first for subnetwork deletion and then for
network deletion.
### 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)
- [ ] Documentation
- [X] [Tests](http://libcloud.readthedocs.org/en/latest/testing.html)
- [ ]
[ICLA](http://libcloud.readthedocs.org/en/latest/development.html#contributing-bigger-changes)
(required for bigger changes)
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/jbaublitz/libcloud
gce_subnetwork_delete_bugfix
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/libcloud/pull/974.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #974
----
commit eeb4b0043884ec4337986e82810bccce39531c40
Author: John Baublitz <[email protected]>
Date: 2017-01-10T16:29:20Z
Patch for deletion against asynchronous Google subnetwork API
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---