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

Allow operation to be blocking #146

Closed
djsly opened this issue Jul 5, 2017 · 3 comments
Closed

Allow operation to be blocking #146

djsly opened this issue Jul 5, 2017 · 3 comments

Comments

@djsly
Copy link

djsly commented Jul 5, 2017

https://github.com/terraform-providers/terraform-provider-digitalocean/issues/19

Has you can see, recently a change in the logic from the API at DO caused some issues with 3rd party app using the GODO product.

It would make sense that the GODO allow calls to be blocking, avoiding the different 3rd party app from doing polling and checking for statuses.

@mauricio
Copy link
Contributor

mauricio commented Jul 6, 2017

Hey @djsly, can you elaborate on what's causing the issue here?

@djsly
Copy link
Author

djsly commented Jul 7, 2017

Hi @mauricio , sure, the issue started last week, where the deletion of the volume (storage) started returning 409. An error about the volume still being attached to a droplet.

So, even though we delete the droplet using the API, we get a 204 request, it was possible before to issue a deletion of the volume right away. Not we have to wait 3-4 sec for the droplet to be deleted for real on the DO side before the volume be we deleted properly.

It would be beneficial that all DELETION requests would return the 204 once and only once the deletion process is completed.
HTTP Status Code 204: The server has successfully fulfilled the request and that there is no additional content to send in the response payload body.

22:29 $ curl -X DELETE -H "Content-Type: application/json" -H "Authorization: Bearer <token>" "https://api.digitalocean.com/v2/droplets/53112244"

✔ ~ 
22:31 $ curl -X DELETE -H "Content-Type: application/json" -H "Authorization: Bearer <token>" "https://api.digitalocean.com/v2/volumes/938b3d10-5ade-11e7-91b8-0242ac116405"

{"id":"Illegal Action","message":"A volume that's attached to a Droplet cannot be deleted. Please detach it first before deleting."}✔ ~ 
22:31 $ 
✔ ~ 
22:31 $ 
✔ ~ 
22:31 $ curl -X DELETE -H "Content-Type: application/json" -H "Authorization: Bearer <token>" "https://api.digitalocean.com/v2/volumes/938b3d10-5ade-11e7-91b8-0242ac116405"
{"id":"Illegal Action","message":"A volume that's attached to a Droplet cannot be deleted. Please detach it first before deleting."}

✔ ~ 
22:31 $ curl -X DELETE -H "Content-Type: application/json" -H "Authorization: Bearer <token>" "https://api.digitalocean.com/v2/volumes/938b3d10-5ade-11e7-91b8-0242ac116405"
✔ ~

@mauricio
Copy link
Contributor

mauricio commented Mar 7, 2018

@mauricio mauricio closed this as completed Mar 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants