Zombie relations remain after a charm was removed with --no-wait
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Triaged
|
High
|
Ian Booth |
Bug Description
If there are 2 related charms, and one of them is removed with ``juju remove-application --force --no-wait``, the second charm will still have a relation set to the now removed charm. If the first charm gets redeployed and related to the second charm, the second charm now has 2 relations.
This can become a problem if the second charm expects to only have one relation set.
Example:
# Add the model, initial charms, and relate them.
juju add-model relations
juju deploy hello-kubecon
juju deploy nginx-ingress-
juju relate hello-kubecon ingress
juju status
# Forcefully remove the hello-kubecon charm.
juju remove-application --force --no-wait hello-kubecon
juju status
# Redeploy the hello-kubecon charm and relate it to the nginx-ingress-
juju deploy hello-kubecon
juju relate hello-kubecon ingress
# The nginx-ingress-
juju status
Having a pdb open into the ``nginx-
> /var/lib/
-> if not self.model.
(Pdb) self.model.
[<ops.model.
Sample output from the commands above: https:/
Note that this is not an issue with the hello-kubecon and nginx-ingress-
juju remove-relation won't clear the zombie relation.
Juju version used: 2.9.27
OS: Ubuntu 20.04
Cloud: Kubernetes (microk8s, EKS)
description: | updated |
description: | updated |
description: | updated |
Changed in juju: | |
assignee: | nobody → Ian Booth (wallyworld) |
importance: | Undecided → High |
status: | New → Triaged |