Comments (3)
Hi @vlad2095,
I'm not able to reproduce this. When deleting a floating IP attached to a Droplet, it is completely deleted, not just unassigned. For example, with doctl
which uses godo
:
$ doctl compute floating-ip create --droplet-id 270960839
IP Region Droplet ID Droplet Name
143.244.220.237 nyc3 270960839 ubuntu-s-1vcpu-1gb-nyc3-02
$ doctl compute floating-ip get 143.244.220.237
IP Region Droplet ID Droplet Name
143.244.220.237 nyc3 270960839 ubuntu-s-1vcpu-1gb-nyc3-02
$ doctl compute floating-ip delete 143.244.220.237 --trace
Warning: Are you sure you want to delete this floating IP? (y/N) ? y
doctl: 2021/10/26 12:11:41 -> "DELETE /v2/floating_ips/143.244.220.237 HTTP/1.1\r\nHost: api.digitalocean.com\r\nUser-Agent: doctl/1.65.0-release (linux amd64) godo/1.69.0\r\nAccept: application/json\r\nContent-Type: application/json\r\nAccept-Encoding: gzip\r\n\r\n"
$ doctl compute floating-ip get 143.244.220.237
Error: GET https://api.digitalocean.com/v2/floating_ips/143.244.220.237: 404 (request "43546723-48f0-428b-98b9-39b027fe1825") The resource you requested could not be found.
Can you share any more details about your code? Can you still reproduce the issue?
from godo.
I can confirm there is an issue here, or at least some undocumented new behavior.
The API states
:\
This used to work as described, but not anymore. There seems to be a new intermediate state between the first FloatingIPs.Delete
and the second FloatingIPs.Delete
, here's a screenshot from the dashboard:
So the status of the floating IP is like this now:
Released
on first call toFloatingIPs.Delete
Removed
on second callFloatingIPs.Delete
The crazy thing is, after the first Delete it becomes Released
and FloatingIPs.Get
fails with 404
which explains what @andrewsomething is seeing with doctl
.
could it be related to floating ip's in custom non-default projects?
My walk-around is to ignore the 404
errors when releasing the IP the second time, here's how I'm doing it:
if gerr, ok := err.(*godo.ErrorResponse); ok {
res := gerr.Response
if res != nil {
switch res.StatusCode {
case 404:
return providers.NewNotFoundError("resource not found in DigitalOcean")
}
}
return gerr
}
Edit: this is not a library issue, it must be at API level. I tried with v1.19.0
which is what I was originally using and the latest v1.73.0
presents the same behavior.
from godo.
Hello @bithavoc,
I passed this on to the internal floating ips team and they could not detect any issue.
I also attempted to reproduce this bug this morning and was able to delete floating ips on the first attempt. I will close this issue as not reproducible. Please re-open if you have any future concerns or comments.
thank you
from godo.
Related Issues (20)
- DropletID sometimes string or int HOT 1
- Enhancement request: Enhance Droplet Create API to also take project id HOT 5
- Add to fetch details of monitoring alert policies. HOT 1
- Add project information in response of list and get call of all resources. HOT 1
- Support for TTL in domain create
- CVE-2021-27918 (High) detected in github.com/golang/net-e086a090c8fdb9982880f0fb6e3db47af1856533 HOT 1
- CVE-2021-31525 (Medium) detected in github.com/golang/net-e086a090c8fdb9982880f0fb6e3db47af1856533 HOT 1
- CVE-2021-33194 (High) detected in github.com/golang/net-e086a090c8fdb9982880f0fb6e3db47af1856533
- Account
- Create Snapshot Missing HOT 2
- [Feature Request] Add specifying image by name support to DropletCreateImage
- Kubernetes `surge_upgrade` field cannot be set to `false` HOT 3
- https://github.com/notxarb/openapi/tree/main
- App
- CVE-2022-27664 (High) detected in github.com/golang/net-290c469a71a567d354e4abd335577aba44c4bde4
- CVE-2022-41721 (High) detected in golang.org/x/net-v0.0.0-20220921155015-db77216a4ee9 HOT 1
- How to get error message HOT 1
- Typo in the Readme # Build Status is not showing an icon HOT 5
- Code of conduct was missing. I added it HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from godo.