canonical / canonical/pycloudlib

ip() calls should get cached

Open
#316 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
22
Forks
42
PR merge metrics
No merged PRs in 30d

Description

Every Instance has an ip() method. In cloud-init, when tearing down, we have the option of keeping instance so that it can be further debugged. To make this easy, we print the IP of the instance being torn down. However, this can cause issues on "clouds" like LXD that dynamically fetch the IP. In my case, I took a snapshot of the instance first, so the instance was shutdown (but not removed). The call to get the IP then retries 150 times, eventually failing.

It's fine (not ideal) if the call fails, but waiting 150 tries is a bit much.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.